Skip to content

Commit

Permalink
fix(widget-loader): use importmapAppNAme instead of name
Browse files Browse the repository at this point in the history
  • Loading branch information
andypf committed Jun 26, 2024
1 parent 8b12268 commit ac7fbc2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
9 changes: 1 addition & 8 deletions apps/widget-loader/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,7 @@
data-name="dashboard"
data-version="latest"
></script> -->
<script
defer
src="./build/app.js"
data-debug="false"
data-origin="https://assets.juno.qa-de-1.cloud.sap"
data-importmap-only="true"
></script>

<script
defer
src="./build/app.js"
Expand All @@ -67,7 +61,6 @@
src="./build/app.js"
data-origin="https://assets.juno.qa-de-1.cloud.sap"
data-name="whois"
data-version="=3.0.2"
data-debug="true"
></script>

Expand Down
2 changes: 1 addition & 1 deletion apps/widget-loader/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ const ESM_SHIM_URL = "/externals/[email protected]/dist/es-module-shims.js"
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[`${name}@${version}`]
let appURL = url || importmap.imports[`${importmapAppName}@${version}`]

// get app props from the data-props-* arguments
let appProps = { currentHost: new URL(appURL).href }
Expand Down

0 comments on commit ac7fbc2

Please sign in to comment.