feat: support embedded import map in deno.json (#1188)
One can now inline the `imports` and `scopes` from the import map directly into deno.json. For new projects, `import_map.json` is not generated anymore. Co-authored-by: Luca Casonato <hello@lcas.dev>
This commit is contained in:
co-authored by
Luca Casonato
parent
3857a49f1c
commit
1b6678951a
@@ -1,6 +1,11 @@
|
||||
{
|
||||
"lock": false,
|
||||
"importMap": "./import_map.json",
|
||||
"imports": {
|
||||
"$fresh/": "../../",
|
||||
"preact": "https://esm.sh/preact@10.15.1",
|
||||
"preact/": "https://esm.sh/preact@10.15.1/",
|
||||
"preact-render-to-string": "https://esm.sh/*preact-render-to-string@6.0.3"
|
||||
},
|
||||
"compilerOptions": {
|
||||
"jsx": "react-jsx",
|
||||
"jsxImportSource": "preact"
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
// This file SHOULD be checked into source version control.
|
||||
// This file is automatically updated during development when running `dev.ts`.
|
||||
|
||||
import config from "./deno.json" assert { type: "json" };
|
||||
import * as $0 from "./routes/static.tsx";
|
||||
import * as $1 from "./routes/with-island.tsx";
|
||||
import * as $$0 from "./islands/Island.tsx";
|
||||
@@ -16,7 +15,6 @@ const manifest = {
|
||||
"./islands/Island.tsx": $$0,
|
||||
},
|
||||
baseUrl: import.meta.url,
|
||||
config,
|
||||
};
|
||||
|
||||
export default manifest;
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
{
|
||||
"imports": {
|
||||
"$fresh/": "../../",
|
||||
"preact": "https://esm.sh/preact@10.15.1",
|
||||
"preact/": "https://esm.sh/preact@10.15.1/",
|
||||
"preact-render-to-string": "https://esm.sh/*preact-render-to-string@6.0.3"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user