The dev option is used to define the development or production mode of your app. It is not added to the Nuxt config file, but you can add it manually when you need to. It only takes a Boolean type and its default is set to true. It is always forced to be true with the nuxt command and always forced to be false with the nuxt build, nuxt start, and nuxt generate commands.
Hence, technically you can't customize it, but you can use this option in a Nuxt module, as follows:
// modules/sample.js
export default function (moduleOptions) {
console.log(this.options.dev)
}
You will get either true or false, depending on which Nuxt command you use. We will cover this module in Chapter 6, Writing Plugins and Modules. Alternatively, you can use this option when you are importing Nuxt as a package in a server-side framework, as follows:
// server/index.js
import { Nuxt, Builder } from 'nuxt'
import config from './nuxt.config.js'
const nuxt = new...