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

CSS Imports #301

Open
trymeouteh opened this issue Jan 25, 2025 · 3 comments
Open

CSS Imports #301

trymeouteh opened this issue Jan 25, 2025 · 3 comments

Comments

@trymeouteh
Copy link

The ability to import CSS styles using import maps.

@justinfagnani
Copy link
Collaborator

This is already supported without import maps with CSS modules and the {type: 'css'} import attribute: https://github.com/WICG/webcomponents/blob/gh-pages/proposals/css-modules-v1-explainer.md

@trymeouteh
Copy link
Author

This is already supported without import maps with CSS modules and the {type: 'css'} import attribute: https://github.com/WICG/webcomponents/blob/gh-pages/proposals/css-modules-v1-explainer.md

This method does not work when JavaScript is disabled in the browser. Would be nice to use importmaps JSON files to import CSS files even when JS is disabled in the browser.

@oscarotero
Copy link

That would be great. Maybe something like:

@import-map "./import-map.json";

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

No branches or pull requests

3 participants