Sorry, but you either have no stories or none are selected somehow.
If the problem persists, check the browser console, or the terminal you've run Storybook from.
The component failed to render properly, likely due to a configuration issue in Storybook. Here are some common causes and how you can address them:
A set of standard Web Components for easy integration with every framework or no framework at all.
Depending on your project setup, there are different ways available to integrate our components.
npm install @swisspost/design-system-components
Import all or only specific components into your entry file (e.g. main.js
, app.js
, ...).
import { defineCustomElements as definePostComponents } from '@swisspost/design-system-components/loader'; definePostComponents();
import { defineCustomElement as definePostIcon } from '@swisspost/design-system-components/dist/components/post-icon'; definePostIcon();
Use the imported components in your html:
<post-icon name="1000"></post-icon>
If you are not using any bundler or don't want to install from npm, you can load our components from your favorite CDN.
Make sure to replace {version}
with the version you want to use or remove @{version}
to use the latest version.
Available CDNs:
{cdnURL}
with https://cdn.jsdelivr.net/npm/@swisspost/design-system-components.{cdnURL}
with https://unpkg.com/@swisspost/design-system-components.Load all components at once
<html> <head> <script type="module"> import { defineCustomElements as definePostComponents } from '{cdnUrl}@{version}/loader/index.js'; definePostComponents(); </script> </head> <body> <post-icon name="1001"></post-icon> </body> </html>
Load specific components only
<html> <head> <script type="module"> import { defineCustomElement as definePostIcon } from '{cdnUrl}@{version}/dist/components/post-icon.js'; definePostIcon(); </script> </head> <body> <post-icon name="1001"></post-icon> </body> </html>
<html> <head> <script src="{cdnUrl}@{version}/dist/index.js"></script> </head> <body> <post-icon name="1001"></post-icon> </body> </html>