Skip to content

Commit 78b40a6

Browse files
authored
Build typedoc before test:storybook & test:storybook:update (#32719)
* Build typedoc before test:storybook & test:storybook:update Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Fix doc --------- Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
1 parent 2e0adc5 commit 78b40a6

File tree

3 files changed

+25
-6
lines changed

3 files changed

+25
-6
lines changed

packages/shared-components/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ function MyApp() {
108108
pnpm install
109109

110110
# Build the library
111-
pnpm prepare
111+
pnpm prepack
112112
```
113113

114114
### Running Storybook

packages/shared-components/package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,14 @@
3838
"i18n": "matrix-gen-i18n src && pnpm i18n:sort && pnpm i18n:lint",
3939
"i18n:sort": "matrix-sort-i18n src/i18n/strings/en_EN.json",
4040
"i18n:lint": "matrix-i18n-lint && prettier --log-level=silent --write src/i18n/strings/ --ignore-path /dev/null",
41-
"test:unit": "vitest --project=unit",
42-
"test:storybook": "pnpm build:doc && vitest --project=storybook",
43-
"test:storybook:update": "CI=1 playwright-screenshots-experimental pnpm vitest --run --update --project=storybook",
41+
"test:unit": "nx test:unit",
42+
"test:storybook": "nx test:storybook",
43+
"test:storybook:update": "nx test:storybook:update",
4444
"build": "nx build",
4545
"prepack": "pnpm run build",
4646
"storybook": "storybook dev -p 6007",
47-
"build:storybook": "nx run @element-hq/web-shared-components:storybook",
48-
"build:doc": "nx run @element-hq/web-shared-components:typedoc",
47+
"build:storybook": "nx storybook",
48+
"build:doc": "nx typedoc",
4949
"lint": "pnpm lint:types && pnpm lint:js",
5050
"lint:js": "eslint --max-warnings 0 src",
5151
"lint:types": "tsc --noEmit && tsc --noEmit -p tsconfig.node.json"

packages/shared-components/project.json

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,25 @@
3232
"cwd": "packages/shared-components"
3333
},
3434
"dependsOn": ["build", "typedoc"]
35+
},
36+
"test:unit": {
37+
"command": "vitest --project=unit",
38+
"options": { "cwd": "packages/shared-components" }
39+
},
40+
"test:storybook": {
41+
"command": "vitest --project=storybook",
42+
"options": { "cwd": "packages/shared-components" },
43+
"dependsOn": ["typedoc"]
44+
},
45+
"test:storybook:update": {
46+
"command": "playwright-screenshots-experimental nx test:storybook --run --update",
47+
"options": {
48+
"env": {
49+
"CI": "1"
50+
},
51+
"cwd": "packages/shared-components"
52+
},
53+
"dependsOn": ["typedoc"]
3554
}
3655
}
3756
}

0 commit comments

Comments
 (0)