fix: check for ESM config instead of try catch (#1139) #1809
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: Test | |
| on: | |
| push: | |
| branches: [main] | |
| paths-ignore: | |
| - 'website/**' | |
| pull_request: | |
| paths-ignore: | |
| - 'website/**' | |
| workflow_dispatch: | |
| jobs: | |
| verify: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| node_version: ['18', '20', '22.6'] | |
| os: [ubuntu-latest] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v3 | |
| - name: Use Node.js ${{ matrix.node_version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node_version }} | |
| cache: 'pnpm' | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Lint | |
| run: pnpm lint:ci | |
| - name: Type check | |
| run: pnpm typecheck | |
| - name: Run tests | |
| run: pnpm test |