Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow custom console in createLogger #18379

Merged
merged 1 commit into from
Oct 26, 2024

Conversation

sheremet-va
Copy link
Member

Description

It's possible to define a console with custom stdout/stderr streams in Node.js by using the Console class:

const console = new Console({ stdout: myCustomStdout })

Vitest uses this mostly to make testing itself easier, but I don't see any harm in allowing the custom console in the logger.

Copy link

stackblitz bot commented Oct 17, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@sheremet-va sheremet-va changed the title feat: allow custom console in createLogger feat: allow custom console in createLogger Oct 17, 2024
@sapphi-red sapphi-red added the p2-nice-to-have Not breaking anything but nice to have (priority) label Oct 18, 2024
@patak-dev patak-dev merged commit 0c497d9 into vitejs:main Oct 26, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p2-nice-to-have Not breaking anything but nice to have (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants