Closed dmail closed 2 years ago
Currently the entry point of the project is resolved from package.json for each importmap file. It works fine but it's a bit "magic" so I would prefer to pass it explicitely.
import { writeImportMapFiles } from "@jsenv/importmap-node-module" await writeImportMapFiles({ projectDirectoryUrl: new URL("./", import.meta.url), importMapFiles: { "./dev.importmap": { mappingsForNodeResolution: true, packageUserConditions: ["development"], + entryPoint: "./main.js" }, "./prod.importmap": { mappingsForNodeResolution: true, packageUserConditions: ["production"], + entryPoint: "./main_prod.js" }, }, })
Currently the entry point of the project is resolved from package.json for each importmap file. It works fine but it's a bit "magic" so I would prefer to pass it explicitely.