Social bar responsiveness #200
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Check Next.js Build | |
| on: | |
| # run on push to every branch | |
| push: | |
| branches: | |
| - "*" | |
| # run on pull request events | |
| pull_request: | |
| types: [opened, reopened] | |
| # allow manual triggers | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| env: | |
| PAYLOAD_SECRET: ${{ secrets.PAYLOAD_SECRET }} | |
| DATABASE_URI: ${{ secrets.DATABASE_URI }} | |
| steps: | |
| # checkout the code | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| # set-up node | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "20" | |
| cache: "npm" | |
| # cache dependencies | |
| - name: Cache npm dependencies | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.npm | |
| key: ${{ runner.os }}-node-${{ hashFiles('package-lock.json') }} | |
| restore-keys: | | |
| ${{ runner.os }}-node- | |
| # install dependencies using npm | |
| - name: Install dependencies | |
| run: npm ci | |
| # build the application | |
| - name: Build Next.js project | |
| run: npm run build |