Skip to content

vue/no-side-effects-in-computed-properties ​

Computed properties must be pure — move side effects to watch or methods

PropertyValue
CategoryReactivity
Default Severitywarning
Confidencehigh
FixableNo
Engineeslint-template
Sincev1.0.0
Frameworksvue, nuxt

Why it matters ​

Computed properties must be pure — move side effects to watch or methods

How to fix ​

Review the finding and update the code according to best practices below.

Agent Guidance ​

Make the computed pure: move mutations and assignments to methods, watchers or event handlers.


Rule source: vue/no-side-effects-in-computed-properties

Released under the MIT License.