Replies: 5 comments 2 replies
-
I have the same problem and cant get around it ! |
Beta Was this translation helpful? Give feedback.
-
In nuxt, building a consola logger with useLogger. import { useLogger } from '@nuxt/kit';
const logger = useLogger();
logger.info('Info log.'); |
Beta Was this translation helpful? Give feedback.
-
The same problem. |
Beta Was this translation helpful? Give feedback.
-
Also having this problem. Tried the default and createConsola method with fancy flag set. Anyone found a solution? |
Beta Was this translation helpful? Give feedback.
-
In my project, I use consola like this 👇 // utils/logger.ts
import { consola } from 'consola'
import { env } from 'node:process'
if (env.NODE_ENV === 'development') {
env.CONSOLA_LEVEL = 'info'
}
export const logger = consola.withTag('YourAppName') |
Beta Was this translation helpful? Give feedback.
-
Hi, I'm trying to use consola in nuxt 3 server routes, but the log styles don't display, I just have white text, like with a regular console.log. How can I access consola?
My current code:
It would be awesome if we could have a utility like this:
Beta Was this translation helpful? Give feedback.
All reactions