0 votes
in VueJS by
Can I use strict mode in production environment?

1 Answer

0 votes
by

No, it is not recommended to use strict mode in production environment. Strict mode runs a synchronous deep watcher on the state tree for detecting inappropriate mutations and it can be quite expensive when you perform large amount of mutations. i.e, It can impact performance if you enable in production mode. Hence it should be handled through build tools,

const store = new Vuex.Store({
  // ...
  strict: process.env.NODE_ENV !== 'production'
})

Related questions

0 votes
asked Sep 12, 2023 in VueJS by GeorgeBell
0 votes
asked Sep 9, 2023 in VueJS by DavidAnderson
...