Skip to content

Proof of Concept: Monitor Component bundle sizes #9120

Proof of Concept: Monitor Component bundle sizes

Proof of Concept: Monitor Component bundle sizes #9120

name: Build Example Apps
on:
pull_request:
types: [opened, synchronize, reopened, "ready_for_review"]
push:
branches:
- main
concurrency:
group: CI-Example-Apps-${{ github.ref }}
cancel-in-progress: true
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
jobs:
build-example-apps:
permissions:
contents: read
strategy:
matrix:
include:
- node-version: 20
example-app: wc-angular12
- node-version: 16
example-app: wc-nuxt2
- node-version: 20
example-app: wc-react17
- node-version: 20
example-app: wc-react18
- node-version: 20
example-app: wc-vue3
name: Build ${{matrix.example-app}} - Node ${{ matrix.node-version }}
uses: ./.github/workflows/install-build.yml
with:
os: ubuntu-latest
node-version: ${{ matrix.node-version }}
build-script: build:examples --filter=${{ matrix.example-app }}
secrets: inherit
deploy-example-apps:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
strategy:
matrix:
include:
- node-version: 20
amplify-app-id: d3krjop5uu4oza
build-script: build:examples
dist-folder: ./apps/examples/wc-angular12/dist/wc-angular12
example-app: wc-angular12
# Using the generate:examples script for static hosting. SSR requires more investigation
- node-version: 16
amplify-app-id: d3puta7o12ynlf
build-script: generate:examples
dist-folder: ./apps/examples/wc-nuxt2/dist
example-app: wc-nuxt2
- node-version: 20
amplify-app-id: d2a3kuvjs3esad
build-script: build:examples
dist-folder: ./apps/examples/wc-react17/dist
example-app: wc-react17
- node-version: 20
amplify-app-id: d1zlc7g0rtfm9g
build-script: build:examples
dist-folder: ./apps/examples/wc-react18/dist
example-app: wc-react18
- node-version: 20
amplify-app-id: dtgmklfymp81v
build-script: build:examples
dist-folder: ./apps/examples/wc-vue3/dist
example-app: wc-vue3
name: Deploy ${{matrix.example-app}}
uses: ./.github/workflows/amplify-deploy.yml
with:
os: ubuntu-latest
node-version: ${{ matrix.node-version }}
amplify-app-id: ${{ matrix.amplify-app-id }}
package-name: ${{ matrix.example-app}}
package-dist-directory: ${{ matrix.dist-folder }}
bucket-name-main: 'pie-example-apps-main'
build-script: ${{ matrix.build-script }}
secrets: inherit