Skip to content

A package to translate an import-map to a node.js policy

Notifications You must be signed in to change notification settings

giltayar/import-map-to-policy

Repository files navigation

import-map-to-policy

Sample application is in main.js.

Setting up

npm ci

Browser application with importmap

To try it out with the builtin importmap-s in Chrome, run npm start and navigate the browser to http://localhost:5000/page. It should show 42 in the page (you need to use at least Chrome 89).

Node application with policy.json

To try it out with the policy, run npm run start:node. You should see 42 output.

(currently doesn't work!)

https://wicg.github.io/import-maps/ https://github.com/WICG/import-maps https://github.com/WICG/import-maps/tree/main/reference-implementation https://github.com/web-platform-tests/wpt/blob/master/import-maps/

About

A package to translate an import-map to a node.js policy

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published