mjbvz / vscode-github-markdown-preview-style

VS Code extension that changes the built-in markdown preview to match Github's styling
https://marketplace.visualstudio.com/items?itemName=bierner.markdown-preview-github-styles
MIT License
301 stars 57 forks source link

Allow using all of github's themes #101

Closed jjspace closed 1 year ago

jjspace commented 1 year ago

2023-04-16_17-02

Summary

I believe the way the new settings are set up will preserve the existing behavior for anyone who had modified them before.

Resolves #89 Resolves #75

Please let me know if you have any questions!

I don't know much about actually publishing extensions so I believe all my changes should work for those who install them but please verify for me so I'm not accidentally breaking this for a bunch of users (myself included)

mjbvz commented 1 year ago

Great work! Looks like a very nice addition. Will test a little more and then publish shortly if everything looks good

jjspace commented 1 year ago

@mjbvz I'm sorry for accidentally creating some extra issues with my changes and making you do extra cleanup (https://github.com/mjbvz/vscode-github-markdown-preview-style/issues/104, https://github.com/mjbvz/vscode-github-markdown-preview-style/issues/103). Can you elaborate a little on why your fixes were needed/the better changes in these cases? (e0286fd5580cf39704a3d3a6666919573c1b04de b2adb1fbadda6957888345b32a55594f218746a5, d01f1e7a1d39f4210572086132ea53c9e255f5e0) Just so I can learn and don't repeat mistakes in the future as I've never worked on vscode extensions before (and "it works fine on my machine" is not a great excuse :laughing:)

ps. using this pr just to avoid excess noise for other users in the issues, wasn't sure the best place for a discussion

mjbvz commented 1 year ago

No worries, the fixes were pretty quick and easy (and the more important break was my fault)

To recap. The first issue was that .cjs doesn't seem to work on web. I fixed that but in the process broke this extension on desktop because I forgot to commit the change that also removed type: "module" in the package.json. type: "module" caused the extension.js script to be loaded as a module, which was now failing because it's commonjs and no longer had a explicit .cjs extension to tell node otherwise. Then finally I had to make sure the build script was treated as a module again by converting to an .mjs file

Probably not a common issue. Will see if I can add a browser debug config to the extension so you can more easily test the extension in browsers