feat(vscode): bundle extension, update icon, fix vsix packaging#88
Open
teezeit wants to merge 2 commits into
Open
feat(vscode): bundle extension, update icon, fix vsix packaging#88teezeit wants to merge 2 commits into
teezeit wants to merge 2 commits into
Conversation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Without bundling, preview-provider.js relied on ../node_modules/wiremd at runtime which broke after ../node_modules was excluded from the vsix. Bundling inlines wiremd so the extension is fully self-contained. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
extension.tsandpreview-provider.tswith esbuild so the vsix is fully self-contained — no runtime dependency onnode_modulesnode_modulesfrom vsix via.vscodeignore— drops package from ~180 MB → ~150 KB*.vsixto.gitignoreesbuildto devDependenciesWhy bundling preview-provider matters
preview-provider.tsimportswiremddirectly. Without bundling it, the compiled JS relied on../node_modules/wiremdat runtime. After excludingnode_modulesfrom the vsix that path no longer exists, breaking styles and JS navigation. Bundling with esbuild inlines wiremd so the extension works correctly after install.Test plan
cd vscode-extension && npm install && npx vsce packageproduces a clean vsix (~150 KB)code --install-extension wiremd-preview-0.1.0.vsixinstalls successfully🤖 Generated with Claude Code