I am looking for a way to disable console.log() for production env.  Something like putting the below code to nuxt.config.js or index.js:
if (process.env.NODE_ENV !== "development") {
  console.log = () => {};
}
I tried it, but it doesn't work. Any help would be appreciated.
My nuxt.config.js is here https://gist.github.com/somaria/9a2b0e06497d13a35fe9eee141a15d07
 
     
    