Skip to content

Commit 25161ec

Browse files
committed
chore: auto import show-pins-element
useful for debugging pinInfo
1 parent 9f6ad43 commit 25161ec

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

.storybook/preview.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ export const parameters = {
66
import { configure, setCustomElements } from '@storybook/web-components';
77
import customElements from '../custom-elements.json';
88

9+
import '../src/utils/show-pins-element';
10+
911
// Configure Storybook Docs Addon for Web Components
1012
setCustomElements(customElements);
1113

CONTRIBUTING.md

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -69,20 +69,15 @@ When working on the `pinInfo` property, it is often useful to visually see the
6969
pins that you define. To see the pin locations, add the `<wokwi-show-pins>`
7070
utility element to your story:
7171

72-
1. Import the element definition into your story, by adding this line at the top
73-
of the story file:
74-
```
75-
import './utils/show-pins-element';
76-
```
77-
2. Wrap your element with the <wokwi-show-pins> element, e.g.
72+
1. Wrap your element with the <wokwi-show-pins> element, e.g.
7873
```
7974
export const HCSR04 = () => html`
8075
<wokwi-show-pins>
8176
<wokwi-hc-sr04></wokwi-hc-sr04>
8277
</wokwi-show-pins>
8378
`;
8479
```
85-
3. When you are happy with the pin definition, please remove the `<wokwi-show-pins>`
80+
2. When you are happy with the pin definition, please remove the `<wokwi-show-pins>`
8681
from your story. It is only a debugging tool, and shouldn't be present in the final story.
8782

8883
## Video Tutorial and Blog Post

0 commit comments

Comments
 (0)