-
install using
npm install @remindgmbh/nuxt-logger
oryarn add @remindgmbh/nuxt-logger
-
add module in nuxt.config.js
export default defineNuxtConfig({ ... modules: [ ... '@remindgmbh/nuxt-logger', ... ] ... })
Set log level in module options:
export default defineNuxtConfig({
...
logger: {
level: 2,
},
...
})
See available log levels here.
Call the auto imported composable useLogger
to start using the logger.
- Run
npm run dev:prepare
to generate type stubs. - Use
npm run dev
to start playground in development mode.