{"id":17215431,"url":"https://github.com/pixtron/storybook-addon-docs-stencil","last_synced_at":"2026-03-07T22:02:20.079Z","repository":{"id":45077915,"uuid":"315904266","full_name":"pixtron/storybook-addon-docs-stencil","owner":"pixtron","description":null,"archived":false,"fork":false,"pushed_at":"2025-01-12T21:45:59.000Z","size":301,"stargazers_count":17,"open_issues_count":2,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-29T04:46:47.003Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pixtron.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2020-11-25T10:27:06.000Z","updated_at":"2025-04-09T10:17:20.000Z","dependencies_parsed_at":"2024-12-26T08:11:20.384Z","dependency_job_id":"29ecf577-1797-402e-bbcd-556a96bb9b05","html_url":"https://github.com/pixtron/storybook-addon-docs-stencil","commit_stats":{"total_commits":21,"total_committers":4,"mean_commits":5.25,"dds":"0.19047619047619047","last_synced_commit":"d8ff69f2e02161c455971ad15317239f1c770716"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/pixtron/storybook-addon-docs-stencil","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixtron%2Fstorybook-addon-docs-stencil","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixtron%2Fstorybook-addon-docs-stencil/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixtron%2Fstorybook-addon-docs-stencil/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixtron%2Fstorybook-addon-docs-stencil/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pixtron","download_url":"https://codeload.github.com/pixtron/storybook-addon-docs-stencil/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixtron%2Fstorybook-addon-docs-stencil/sbom","scorecard":{"id":736018,"data":{"date":"2025-08-18","repo":{"name":"github.com/pixtron/storybook-addon-docs-stencil","commit":"56a238bd39e2edd92b60846d4101bb4bb292c992"},"scorecard":{"version":"v5.2.1-41-g40576783","commit":"40576783fda6698350fcbbeaea760ff827433034"},"score":1.7,"checks":[{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#dangerous-workflow"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#code-review"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#sast"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#pinned-dependencies"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":0,"reason":"11 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-xffm-g5w8-qvg7","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-67mh-4wv8-2f99","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w","Warn: Project is vulnerable to: GHSA-vg6x-rcgg-rjx6","Warn: Project is vulnerable to: GHSA-x574-m823-4x7w","Warn: Project is vulnerable to: GHSA-4r4m-qw57-chr8","Warn: Project is vulnerable to: GHSA-xcj6-pq6g-qj4x","Warn: Project is vulnerable to: GHSA-356w-63v5-8wf4","Warn: Project is vulnerable to: GHSA-859w-5945-r5v3"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-22T15:51:55.272Z","repository_id":45077915,"created_at":"2025-08-22T15:51:55.272Z","updated_at":"2025-08-22T15:51:55.272Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30233429,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T19:01:10.287Z","status":"ssl_error","status_checked_at":"2026-03-07T18:59:58.103Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-15T03:24:24.177Z","updated_at":"2026-03-07T22:02:20.062Z","avatar_url":"https://github.com/pixtron.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# storybook-addon-docs-stencil\n\nConverts stencil.js doc json derived from stencils output target\n[`docs-json`](https://stenciljs.com/docs/docs-json) to storybook\n[`ArgTypes`](https://storybook.js.org/docs/react/api/argtypes).\n\nWith this addon activated\n\n- Storybook will render basic controls for properties [Controls](https://storybook.js.org/docs/react/essentials/controls).\n- Storybook will auto generate documentation for Props, Events, Methods, Slots, Shadow Parts and Custom Properties.\n- Storybook doc page will contain stencils component documentation (readme.md or inline)\n\n## Installation\n\n```bash\nnpm i -D @pxtrn/storybook-addon-docs-stencil\n```\n\n## Usage\n\n### Configure stencil to generate docs-json at build time.\n\n```js\n// stencil.config.ts\n\nimport { Config } from '@stencil/core';\n\nexport const config: Config = {\n  outputTargets: [\n    {\n      type: 'docs-json',\n      file: 'path/to/docs.json'\n    }\n  ]\n};\n```\n\n### Configure Storybook\n\n```js\n//.storybook/main.js\n\nmodule.exports = {\n  addons: [\n    '@storybook/addon-essentials',\n    '@pxtrn/storybook-addon-docs-stencil',\n  ],\n};\n```\n\n```js\n//.storybook/preview.js\n\nimport { setStencilDocJson } from '@pxtrn/storybook-addon-docs-stencil';\nimport docJson from 'path/to/docs.json';\nif (docJson) setStencilDocJson(docJson);\n\nexport const parameters = {\n  controls: { hideNoControlsWarning: true },\n};\n```\n\n### Configure the argTypes extractor\n\n```js\n//.storybook/preview.js\n\nimport { extractArgTypesFactory } from '@pxtrn/storybook-addon-docs-stencil';\n\n/** @type { import('@pxtrn/storybook-addon-docs-stencil').ExtractArgTypesOptions } */\nconst options = {\n  excludeCategories: 'porperties',\n  controlsFor: 'attributes',\n  eventNameing: 'jsx',\n};\n\nexport const parameters = {\n  docs: {\n    extractArgTypes: extractArgTypesFactory(options),\n  },\n};\n```\n\n#### ExtractArgTypesOptions\n\n- `excludeCategories: Category[]`: categories to exclude from argTypes and docs (default: `['attributes]`).\n- `controlsFor: 'attributes' | 'properties'`: for wich category to render controls.\n- `eventNameing: 'native' | 'jsx'`: nameing of the arg key for events (default: 'native'). If jsx the args can be spread `\u003cmy-component {...args} /\u003e` when using JSX to render stories.\n\n### Default render method\n\nWhen using @storybook/web-components or @storybook/html as renderer args and actions do not get bound automatically. This addon includes an optional default renderer that works out of the box\n\n```js\n//.storybook/preview.js\n\nimport {\n  extractArgTypesFactory,\n  stencilRender,\n} from '@pxtrn/storybook-addon-docs-stencil';\n\n/** @type { import('@storybook/web-components').Preview } */\nconst preview = {\n  render: stencilRender(),\n};\n\nexport default preview;\n```\n\n`stencilRender` can be configured by these options:\n\n- `eventNameing: 'native' | 'jsx'`: use the same nameing used in ExtractArgTypesOptions (default: 'native)\n- `bindEvents: boolean`: wheter events/actions should be bound (default: true)\n\neg:\n\n```js\nstencilRender({ bindEvents: false });\n```\n\n### Component documentation\n\n#### readme.md\n\nIf not already created by stencil create `src/components/my-component/readme.md`\nIf the line `\u003c!-- Auto Generated Below --\u003e` is not present, stencil will ignore this file.\n\n```md\nEverything above this line will be included in storybook\n\n\u003c!-- Auto Generated Below --\u003e\n```\n\n#### inline documentation\n\n```ts\n// src/components/my-component/my-component.tsx`\n\n/**\n * Everything written here will be included, if readme.md is not present.\n */\n@Component({\n  tag: 'my-component',\n  styleUrl: 'my-component.css',\n  shadow: true,\n})\n```\n\nIf you prefere the inline documentation over the readme, see [issue #15](https://github.com/pixtron/storybook-addon-docs-stencil/issues/15#issuecomment-2387147999).\n\n#### Troubleshooting\n\n##### Hint your component in your stories\n\n```ts\n// your-story.ts\n\nexport default {\n  title: 'My Component',\n  component: 'my-component',\n};\n```\n\n### Breaking Changes in v7\n\n- attributes and properties are now shown as own categories, before both where visible under \"props\" with some inconsitency in naming (dashCase vs camelCase). Use `excludeCategories` to configure which categories are shown.\n- removed configuration `dashCase` properties and attributes are now shown in single sections. Use `controlsFor` and `excludeCategories` instead of `dashCase`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixtron%2Fstorybook-addon-docs-stencil","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpixtron%2Fstorybook-addon-docs-stencil","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixtron%2Fstorybook-addon-docs-stencil/lists"}