8.0.7 • Published 1 year ago

@chialab/storybook-dna v8.0.7

Weekly downloads
13
License
MIT
Repository
github
Last release
1 year ago

DNA Storybook

The library used to render Storybook stories with DNA.

This module is used internally by the @chialab/storybook-dna-vite package. If you are setting up a Storybook for DNA components, you should refer to this documentation.

API

The module exposes a set of APIs to enhance Storybook documentation.

getCustomElementsManifest()

This method can be used to retrieve a registered Custom Elements Manifest.

import { getCustomElementsManifest } from '@chialab/storybook-dna';

const manifest = getCustomElementsManifest();
manifest.modules.forEach(() => {
    //
});

setCustomElementsManifest(manifest)

Register a global Custom Elements Manifest.

import { setCustomElementsManifest } from '@chialab/storybook-dna';

setCustomElementsManifest({
    schemaVersion: '1.0.0',
    modules: [
        ...
    ],
});

mergeCustomElementsManifests(manifest1, manifest2)

Multiple generated manifests can be merged in a single global manifest.

import { getCustomElementsManifest, setCustomElementsManifest, mergeCustomElementsManifests } from '@chialab/storybook-dna';

const globalManifest = getCustomElementsManifest();
const manifest = {
    schemaVersion: '1.0.0',
    modules: [
        ...
    ],
};

setCustomElementsManifest(
    mergeCustomElementsManifests(globalManifest, manifest)
);

License

DNA Storybook are released under the MIT license.

8.0.7

1 year ago

8.0.6

1 year ago

8.0.5

1 year ago

8.0.4

1 year ago

8.0.3

1 year ago

8.0.1

1 year ago

8.0.2

1 year ago

8.0.0

1 year ago

8.0.0-alpha.8

1 year ago

8.0.0-alpha.7

2 years ago

8.0.0-alpha.6

2 years ago

8.0.0-alpha.5

2 years ago

7.1.0-alpha.4

2 years ago

7.1.0-alpha.3

2 years ago

7.1.0-alpha.0

2 years ago

7.1.0-alpha.1

2 years ago

7.1.0-alpha.2

2 years ago

7.0.0

2 years ago

7.0.0-rc.0

2 years ago

7.0.0-beta.53

2 years ago

5.3.18

5 years ago

5.3.18-rc.0

5 years ago

5.3.18-beta.26

5 years ago

5.3.18-beta.24

5 years ago

5.3.18-beta.25

5 years ago

5.3.18-beta.23

5 years ago

5.3.18-beta.19

5 years ago

5.3.18-beta.20

5 years ago

5.3.18-beta.18

5 years ago

5.3.18-beta.17

5 years ago

5.3.18-beta.16

5 years ago

6.0.0-alpha.30.1

5 years ago

6.0.0-alpha.30.0

5 years ago