-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(importmap): add @juno scope if unscoped
importmap and widgetLoader: add @juno scope if package is unscoped. This is the case for sapcc/juno packages
- Loading branch information
Showing
4 changed files
with
7 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -144,9 +144,10 @@ const ESM_SHIM_URL = "/externals/[email protected]/dist/es-module-shims.js" | |
// else the version is not changed | ||
} | ||
|
||
const importmapAppName = name?.startsWith("@") ? name : `@juno/${name}` | ||
// get the app URL | ||
// from given url or from importmap based on name and version | ||
let appURL = url || importmap.imports[`@juno/${name}@${version}`] | ||
let appURL = url || importmap.imports[`${name}@${version}`] | ||
|
||
// get app props from the data-props-* arguments | ||
let appProps = { currentHost: new URL(appURL).href } | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters