storybookjs / storybook

Storybook is the industry standard workshop for building, documenting, and testing UI components in isolation
https://storybook.js.org
MIT License
83.94k stars 9.21k forks source link

Rework file transformation logic [yann] #28684

Closed yannbf closed 1 month ago

greptile-apps[bot] commented 1 month ago

Disclaimer This information might be inaccurate, due to it being generated automatically To rework the file transformation logic, follow these steps:

  1. Update Input Files: Modify the input files located in /code/lib/codemod/src/transforms/__testfixtures__/update-organisation-name and /code/lib/codemod/src/transforms/__testfixtures__/csf-hoist-story-annotations to reflect the new transformation logic.

  2. Modify Transformation Logic: Update the transformation logic in the relevant transform files. For example, if you are working on the update-organisation-name transform, locate the transform file and adjust the logic to meet the new requirements.

  3. Update Snapshot Tests: Ensure that the snapshot tests in update-organisation-name.output.snapshot and csf-hoist-story-annotations output snapshot files are updated to reflect the expected output of the new transformation logic.

  4. Run Tests: Execute the tests to ensure that the new transformation logic works as expected and that all snapshots are correctly updated.

References

/.github/DISCUSSION_TEMPLATE/help.yml /.github/DISCUSSION_TEMPLATE/ideas.yml /.github/comments/invalid-link.md /.github/comments /.github/DISCUSSION_TEMPLATE /.github/DISCUSSION_TEMPLATE/rfc.yml /docs/_snippets/custom-build-script-production.md /code/lib/codemod/src/transforms/testfixtures/update-organisation-name /code/lib/codemod/src/transforms/testfixtures/csf-hoist-story-annotations /test-storybooks/ember-cli/ember-output/storybook-docgen /code/lib/cli/src/automigrate/fixes/new-frameworks.ts /code/lib/codemod/src/transforms/csf-hoist-story-annotations.js /test-storybooks/ember-cli/README.md /code/renderers/server/template/cli/button.stories.json /CONTRIBUTING.md /docs/_snippets/test-runner-with-index-json.md /code/lib/codemod/README.md /docs/configure/webpack.mdx /code/core/src/core-server/utils/mockdata/errors/NoMeta.stories.ts /docs/contribute/documentation/documentation-updates.mdx /docs/_snippets/storybook-preview-with-angular-polyfills.md /code/lib/codemod/src/transforms/update-organisation-name.js /docs/_snippets/test-runner-no-index-json.md /docs/get-started/why-storybook.mdx /code/lib/codemod/src/transforms/testfixtures/storiesof-to-csf

#### About Greptile This response provides a starting point for your research, not a precise solution. Help us improve! Please leave a ๐Ÿ‘ if this is helpful and ๐Ÿ‘Ž if it is irrelevant. [Ask Greptile](https://app.greptile.com/chat/github/storybookjs/storybook/next) ยท [Edit Issue Bot Settings](https://app.greptile.com/apps/github)
yannbf commented 1 month ago

Closed by https://github.com/storybookjs/vitest-plugin/pull/2