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

support dev streaming logs #1203

Merged
merged 2 commits into from
Oct 6, 2020
Merged

support dev streaming logs #1203

merged 2 commits into from
Oct 6, 2020

Conversation

FredKSchott
Copy link
Owner

@FredKSchott FredKSchott commented Oct 4, 2020

Changes

Testing

  • Tested manually.

Docs

  • Added to docs site + config schema.

@FredKSchott FredKSchott requested a review from a team as a code owner October 4, 2020 02:12
@vercel
Copy link

vercel bot commented Oct 4, 2020

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/pikapkg/snowpack/33w5q8wk8
✅ Preview: https://snowpack-git-stream-dev-output.pikapkg.vercel.app

stdOutput = stdOutput.replace(/\x1Bc/, '').replace(/\u001bc/, '');
}
if (cmdProgram === 'tsc') {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

related: WORKER_UPDATE was no longer used, so this entire block had essentially become a no-op. Safe to remove

@@ -92,6 +93,7 @@ const configSchema = {
fallback: {type: 'string'},
bundle: {type: 'boolean'},
open: {type: 'string'},
output: {type: 'string', enum: ['stream', 'dashboard']},
Copy link
Collaborator

@drwpow drwpow Oct 5, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’m thinking about output as a CLI flag (e.g. snowpack dev --output=stream) and I’m slightly-against it because the way we’ve implemented these (code), it seems like it could conflict with a future output in another namespace (like if we added a buildOptions.output or installOptions.output).

Is there a more clear name that relates to logging than “output?” What about logStyle?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eh tbh I think this is okay to wait until we hit that issue. We could just as easily choose a more specific name for that second "output" when we get to it. As mentioned above, the idea is to match the same "output" option that we support in the run plugin today.

snowpack/tsconfig.json Outdated Show resolved Hide resolved
Copy link
Collaborator

@drwpow drwpow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving as this looks good and can be merged as-is. But see question on a “permanent” CLI flag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for streaming dev logs
2 participants