diff --git a/.github/workflows/chromatic.yml b/.github/workflows/chromatic.yml index d1e385e..1a0b27a 100644 --- a/.github/workflows/chromatic.yml +++ b/.github/workflows/chromatic.yml @@ -29,8 +29,16 @@ jobs: with: node-version: 18 - - name: Install dependencies - run: npm install + - name: cache dependencies + id: cache + uses: actions/cache@v4 + with: + path: '**/node_modules' + key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}-storybook + + - name: depedency install + if: steps.cache.outputs.cache-hit != 'true' + run: npm ci - name: Build Storybook run: npm run build-storybook @@ -40,7 +48,7 @@ jobs: uses: chromaui/action@latest with: projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }} - storybookBuildDir: /tmp/chromatic-storybook + - name: Comment PR with Storybook link uses: thollander/actions-comment-pull-request@v1