[csswg-drafts] [css-cascade-4] [css-values-4] `@import` should be able to use Import Maps (#8297)

argyleink has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-cascade-4] [css-values-4] `@import` should be able to use Import Maps ==
Javascript imports can now be managed easier with [Import Maps](https://github.com/WICG/import-maps), a very welcomed feature for the web community. I propose being able to add entries to this map and use them from CSS `@import`. Feature matching CSS and JS imports.

## Use case / example
Given the following import map:

```json
{
  "imports": {
    "$fresh/": "https://deno.land/x/fresh@1.1.2/",
    "$design-system": "https://unpkg.com/open-props"
  }
}
```

In JS (works today):

```js
import OpenProps from '$design-system/open-props.module.js'
```

In CSS (proposed feature alignment):

```css
@import "$design-system/open-props.min.css" layer(design.system);
```



Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8297 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 10 January 2023 18:29:59 UTC