-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Use styleModule in prebuilt extensions #9460
Conversation
In jupyterlab#9427, we introduced a new styleModule key instead of guessing about there being a js file corresponding to a style file. That change did not propagate to prebuilt extensions. This commit fixes prebuilt extensions to use styleModule if available. Fixes jupyterlab#9459
Thanks for making a pull request to JupyterLab! To try out this branch on binder, follow this link: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Good news: this does work (minimally) Bad news: importing specific modules in a package (e.g., I think we can solve these issues by changing our build system for 3.1—I don't think that any of the changes to make these work requires a breaking change. Good news 2: likely this is a corner case that is rare among extensions (importing dependency css, or importing from a tokens file or other non-main module in a package, and wanting it to be deduped). Good news 3: source extensions should be deduped as usual - this only becomes a limitation of prebuilt extensions. |
Merging since this (a) fixes a bug and (b) makes things consistent, even if it isn't helpful in practice yet. |
I experimented with a fix in #9475 |
References
Fixes #9459
Follow up on #9427
Code changes
In #9427, we introduced a new styleModule key instead of guessing about there being a js file corresponding to a style file. That change did not propagate to prebuilt extensions. This commit fixes prebuilt extensions to use styleModule if available.
Still draft while I modify one of the examples to use styleModule and at least manually check that it is working.
User-facing changes
Backwards-incompatible changes