Feel free to reject this PR, I'm not easy to offend and you've been very patient w/ me so far!
This PR is a no-op as far as the final packaged code is concerned. But (I think) it offers a minor improvement in terms of developer experience and maintainability (and also it's kind of a cool nifty little webpack trick).
Context:
webpack has a raw-loader to import any file as a string
any import statement can declare inline which loader to use with the following syntax
import txt from 'raw-loader!./file.txt';
the themeStyles stylesheet is meant to be used as a string, but is easier to author / read / maintain as a css file
Changes:
themeStyles.ts becomes themeStyles.css which makes it more clear what this file is from just its name, and allows VSCode to apply CSS syntax highlighting automatically;
webview.ts imports themeStyles.css as a string and the rest is the same as before.
Feel free to reject this PR, I'm not easy to offend and you've been very patient w/ me so far!
This PR is a no-op as far as the final packaged code is concerned. But (I think) it offers a minor improvement in terms of developer experience and maintainability (and also it's kind of a cool nifty little webpack trick).
Context:
raw-loader
to import any file as a stringChanges:
themeStyles.ts
becomesthemeStyles.css
which makes it more clear what this file is from just its name, and allows VSCode to apply CSS syntax highlighting automatically;webview.ts
importsthemeStyles.css
as a string and the rest is the same as before.