generated from productdevbookcom/nuxt-bundle-template
-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
13 changed files
with
937 additions
and
1,307 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,10 @@ concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: | ||
contents: read | ||
pull-requests: write | ||
|
||
on: | ||
push: | ||
branches: | ||
|
@@ -23,48 +27,33 @@ jobs: | |
os: [ubuntu-latest] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: pnpm/[email protected] | ||
- uses: actions/checkout@v4 | ||
|
||
- run: corepack enable | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18.x | ||
node-version: '18' | ||
cache: pnpm | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "pnpm_cache_dir=$(pnpm store path)" >> $GITHUB_OUTPUT | ||
- name: 📦 Install dependencies | ||
run: pnpm install --frozen-lockfile | ||
|
||
- uses: actions/cache@v3 | ||
name: Setup pnpm cache | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-main-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-main- | ||
- name: 📦 Install deps (with cache) | ||
run: pnpm install --child-concurrency 3 | ||
- name: 👀 Lint | ||
run: pnpm lint | ||
|
||
- name: 🚀 Build | ||
run: pnpm build | ||
|
||
- name: 👀 Lint | ||
run: pnpm lint | ||
|
||
# - name: 🧪 Test | ||
# run: pnpm test | ||
# env: | ||
# VITE_TEST_DB_URL: ${{ secrets.VITE_TEST_DB_URL }} | ||
|
||
# - name: 🧪 Test with coverage | ||
# run: pnpm coverage | ||
# env: | ||
# VITE_TEST_DB_URL: ${{ secrets.VITE_TEST_DB_URL }} | ||
- name: 🧪 Test with coverage | ||
run: pnpm coverage | ||
env: | ||
VITE_TEST_DB_URL: ${{ secrets.VITE_TEST_DB_URL }} | ||
|
||
# - name: 📝 Upload coverage | ||
# if: always() | ||
# uses: davelosert/vitest-coverage-report-action@v1 | ||
- name: 📝 Upload coverage | ||
if: always() | ||
uses: davelosert/vitest-coverage-report-action@v2 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
{ | ||
// Enable the ESlint flat config support | ||
"eslint.experimental.useFlatConfig": true, | ||
"references.preferredLocation": "peek" | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import antfu from '@antfu/eslint-config' | ||
|
||
export default antfu() |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
{ | ||
"compilerOptions": { | ||
"target": "ES2020", | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"jsx": "preserve", | ||
"useDefineForClassFields": true, | ||
"module": "ESNext", | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"skipLibCheck": true, | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"resolveJsonModule": true, | ||
"isolatedModules": true, | ||
"noEmit": true, | ||
"jsx": "preserve", | ||
"isolatedModules": true, | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noFallthroughCasesInSwitch": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
"skipLibCheck": true | ||
}, | ||
"include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"], | ||
"references": [{ "path": "./tsconfig.node.json" }] | ||
"references": [{ "path": "./tsconfig.node.json" }], | ||
"include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"] | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
{ | ||
"compilerOptions": { | ||
"composite": true, | ||
"skipLibCheck": true, | ||
"module": "ESNext", | ||
"moduleResolution": "bundler", | ||
"allowSyntheticDefaultImports": true | ||
"allowSyntheticDefaultImports": true, | ||
"skipLibCheck": true | ||
}, | ||
"include": ["vite.config.ts"] | ||
} |
Oops, something went wrong.