Skip to content

Commit 3f8b1d4

Browse files
author
Callin Mullaney
committed
chore: expose project audit in whisk
1 parent f5f37a6 commit 3f8b1d4

2 files changed

Lines changed: 19 additions & 7 deletions

File tree

UPGRADE.md

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,30 @@ Emulsify 7.x is a breaking release. Plan the upgrade as a theme-platform change,
3333
- Frontend workflow references should move from Webpack-based build workflow commands and docs to the Vite-based build workflow shipped in 7.x.
3434
- `whisk` remains a starter source only. Do not enable it as a runtime parent theme.
3535

36-
## Twig Story Migration Audit
36+
## Project Audit
3737

38-
Generated themes include an audit command for reviewing older Twig stories that
39-
should move to Emulsify Core's preferred `renderTwig()` helper:
38+
Generated themes include an audit command for reviewing common frontend upgrade
39+
items:
40+
41+
```bash
42+
npm run audit
43+
```
44+
45+
The command reports Storybook discovery issues, unresolved Twig `include()` or
46+
`source()` references, Webpack-era patterns, direct imports of Emulsify Core
47+
internals, platform assumptions, source-root issues, large Twig Storybook roots,
48+
and older Twig stories that should move to Emulsify Core's preferred
49+
`renderTwig()` helper.
50+
51+
For only the Twig story migration report, run:
4052

4153
```bash
4254
npm run audit:twig-stories
4355
```
4456

45-
The command prints a report of likely legacy Storybook files and links to the
46-
Emulsify Core Storybook migration documentation. Existing Twig stories that
47-
return HTML strings can continue rendering during the upgrade, but actively
48-
maintained stories should be migrated to `renderTwig()` as they are touched.
57+
Existing Twig stories that return HTML strings can continue rendering during the
58+
upgrade, but actively maintained stories should be migrated to `renderTwig()` as
59+
they are touched.
4960

5061
## Theme Architecture Changes
5162

whisk/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"type": "module",
1919
"scripts": {
2020
"a11y": "npm run storybook-build && node_modules/@emulsify/core/scripts/a11y.js -r",
21+
"audit": "sh -c 'node_modules/@emulsify/core/scripts/audit.js \"$@\"; status=$?; printf \"\\nAudit docs: https://github.com/emulsify-ds/emulsify-core/blob/4.x/docs/migration-4x.md#storybook-migration\\n\"; exit $status' --",
2122
"audit:twig-stories": "sh -c 'node_modules/@emulsify/core/scripts/audit-twig-stories.js \"$@\"; status=$?; printf \"\\nMigration docs: https://github.com/emulsify-ds/emulsify-core/blob/4.x/docs/storybook.md#legacy-twig-story-compatibility\\n\"; exit $status' --",
2223
"build": "npm run ensure-dist && vite --config node_modules/@emulsify/core/config/vite/vite.config.js",
2324
"coverage": "npm run test && open-cli .coverage/lcov-report/index.html",

0 commit comments

Comments
 (0)