Skip to content

Commit

Permalink
ci(lighthouse): only for suspensive.org (#695)
Browse files Browse the repository at this point in the history
# Overview

<!--
    A clear and concise description of what this pr is about.
 -->

## PR Checklist

- [x] I did below actions if need

1. I read the [Contributing
Guide](https://github.com/suspensive/react/blob/main/CONTRIBUTING.md)
2. I added documents and tests.
  • Loading branch information
manudeli authored Feb 4, 2024
1 parent 2645f25 commit 6349cc6
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 13 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,28 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
command: ['lint', 'lint:attw', 'lint:monorepo', 'lint:pub', 'test', 'test:production', 'type:check', 'build']
command:
[
'lint',
'lint:attw',
'lint:monorepo',
'lint:pub',
'test',
'test:production',
'type:check',
'build',
'ci:lighthouse',
]
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/pnpm-setup-node
- run: pnpm install --frozen-lockfile
- if: matrix.command == 'test'
run: pnpm playwright install
- run: pnpm ${{ matrix.command }}
env:
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }}
- if: matrix.command == 'test'
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- if: matrix.command == 'build'
run: pnpm ci:lighthouse
env:
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }}
5 changes: 3 additions & 2 deletions .lighthouserc.cjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
module.exports = {
ci: {
collect: {
url: ['http://localhost:4000/', 'http://localhost:4001/', 'http://localhost:4100/'],
startServerCommand: 'pnpm start',
url: ['http://localhost:4001/', 'http://localhost:4001/docs/why/'],
startServerCommand: 'pnpm start --filter=@suspensive/suspensive.org',
numberOfRuns: 2,
},
upload: {
target: 'temporary-public-storage',
Expand Down
12 changes: 6 additions & 6 deletions websites/visualization/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@
"incremental": true,
"plugins": [
{
"name": "next"
}
"name": "next",
},
],
"paths": {
"~/*": ["./src/*"]
}
"~/*": ["./src/*"],
},
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "./.eslintrc.cjs"],
"exclude": ["node_modules", ".next"]
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "./.eslintrc.cjs", "next.config.js"],
"exclude": ["node_modules", ".next"],
}

0 comments on commit 6349cc6

Please sign in to comment.