storybook/docs/snippets/web-components/component-story-static-asset-cdn.js.mdx
2023-02-16 09:13:06 +08:00

23 lines
513 B
Plaintext

```js
// MyComponent.stories.js
import { html } from 'lit';
export default {
title: 'img',
component: 'my-component',
};
/*
*👇 Render functions are a framework specific feature to allow you control on how the component renders.
* See https://storybook.js.org/docs/7.0/web-components/api/csf
* to learn how to use render functions.
*/
export const WithAnImage = {
render: () => html`<img
src="https://storybook.js.org/images/placeholders/350x150.png"
alt="My CDN placeholder"
/>`,
};
```