Skip to content
This repository was archived by the owner on Jan 5, 2023. It is now read-only.

Commit 25c4e2b

Browse files
committed
ADD github action
1 parent 68c799f commit 25c4e2b

File tree

3 files changed

+1228
-21
lines changed

3 files changed

+1228
-21
lines changed

.github/workflows/chromatic.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: "Chromatic"
2+
on:
3+
pull_request:
4+
5+
jobs:
6+
test:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
- run: |
11+
yarn
12+
- run: |
13+
yarn build
14+
- run: |
15+
yarn build-storybook
16+
- uses: chromaui/action@v1
17+
with:
18+
appCode: ${{ secrets.CHROMATIC_APP_CODE }}
19+
token: ${{ secrets.GITHUB_TOKEN }}
20+
storybookBuildDir: storybook-static
21+

package.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"clean": "rimraf ./dist",
1111
"compile": "babel ./src --out-dir ./dist",
1212
"prepublish": "npm run clean && npm run compile",
13+
"build-storybook": "build-storybook",
1314
"storybook": "start-storybook -p 9010",
1415
"test": "jest"
1516
},
@@ -28,8 +29,8 @@
2829
"@storybook/client-logger": "^5.0.0",
2930
"@storybook/react": "^5.0.0",
3031
"babel-loader": "^8.0.4",
31-
"css-loader": "^3.1.0",
3232
"core-js": "^3.0.1",
33+
"css-loader": "^3.1.0",
3334
"eslint-config-taller": "^2.0.0",
3435
"eslint-plugin-flowtype": "^3.5.1",
3536
"jest": "^24.7.1",
@@ -44,5 +45,8 @@
4445
"@storybook/react": "^5.0.0",
4546
"babel-plugin-react-docgen": "^2.0.0",
4647
"react": ">=15.0.0 || ^16.0.0"
48+
},
49+
"dependencies": {
50+
"storybook-chromatic": "^3.0.3"
4751
}
4852
}

0 commit comments

Comments
 (0)