diff --git a/react/index.ts b/react/index.ts index dae874f..f4f998b 100644 --- a/react/index.ts +++ b/react/index.ts @@ -1,6 +1,11 @@ // Index to import all components together // import '@hotosm/ui/react'; +// setBasePath makes the icons available via CDN, instead of expecting them to be +// on the webserver the runs the web-component +import { setBasePath } from '@shoelace-style/shoelace/dist/utilities/base-path.js'; +setBasePath('https://cdn.jsdelivr.net/npm/@hotosm/ui@latest/dist'); + export { default as Button } from './Button'; export { default as Header } from './Header'; export { default as Toolbar } from './Toolbar';