| name: Bundle-size | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| env: | |
| TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | |
| TURBO_TEAM: ${{ secrets.TURBO_TEAM }} | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref_name }} | |
| cancel-in-progress: true | |
| jobs: | |
| size: | |
| name: 'Bundle Size' | |
| if: github.repository == 'pmndrs/react-spring' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: 'yarn' | |
| - name: Install | |
| run: yarn install --immutable | |
| - name: Build packages | |
| run: yarn build --filter=!@react-spring/docs | |
| - uses: preactjs/compressed-size-action@v2 | |
| with: | |
| pattern: '{**/dist/**/*.{mjs,js},packages/types/*.{js,d.ts}}' | |