Skip to content

Commit

Permalink
build(deps): add pkg-ok to validate package configuration #81
Browse files Browse the repository at this point in the history
  • Loading branch information
nerdyman committed Apr 7, 2023
1 parent 55ce027 commit e0ff502
Show file tree
Hide file tree
Showing 8 changed files with 2,600 additions and 2,213 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dist/
coverage/
.nyc_output/
*.ignore
.pnpm-store/
pnpm-lock.yaml
storybook-static/
.next/
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,12 @@ jobs:
- name: 🔨 Build
run: pnpm run build

- name: 🕵️ Check Package Configuration
run: pnpm run check:package

- name: 🧪 Test
run: |
npx playwright install chromium
pnpm dlx playwright install chromium
pnpm run --filter @this/example build
pnpm run test:ci
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ dist
coverage
*.ignore
.next/
.pnpm-store/
storybook-static
docs/storybook/src
3 changes: 2 additions & 1 deletion .npmrc → .npmrc.off
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# @see https://github.com/storybookjs/builder-vite/issues/55
public-hoist-pattern[]=*storybook*
public-hoist-pattern[]=@storybook/*
public-hoist-pattern[]=*@storybook/*
public-hoist-pattern[]=@storybook/addon-docs/preview
public-hoist-pattern[]=@mdx-js/react
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dist/
coverage/
.nyc_output/
*.ignore
.pnpm-store/
pnpm-lock.yaml
storybook-static/
.next/
Expand Down
2 changes: 2 additions & 0 deletions docs/storybook/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,12 @@
"devDependencies": {
"@storybook/addon-console": "^1.2.3",
"@storybook/addon-coverage": "^0.0.8",
"@storybook/addon-docs": "^7.0.2",
"@storybook/addon-essentials": "^7.0.2",
"@storybook/addon-interactions": "^7.0.2",
"@storybook/addon-links": "^7.0.2",
"@storybook/addon-storysource": "^7.0.2",
"@storybook/blocks": "^7.0.2",
"@storybook/builder-vite": "^7.0.2",
"@storybook/jest": "^0.1.0",
"@storybook/preset-typescript": "^3.0.0",
Expand Down
16 changes: 9 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"portrait",
"typescript"
],
"packageManager": "pnpm@7.22.0",
"packageManager": "pnpm@8.1.1",
"sideEffects": false,
"module": "dist/index.mjs",
"typings": "dist/index.d.ts",
Expand All @@ -39,14 +39,15 @@
"clean": "rm -rvf ./node_modules ./docs/*/node_modules",
"dev": "tsup --watch",
"dx": "npm run bootstrap && pnpm run prepare && pnpm run prepare",
"start": "concurrently -k -s first -n \"tsup,ts\" -c \"blue,cyan\" \"pnpm run dev\" \"pnpm run type:check --watch\"",
"build": "pnpm run type:check && NODE_ENV=production tsup",
"start": "concurrently -k -s first -n \"tsup,ts\" -c \"blue,cyan\" \"pnpm run dev\" \"pnpm run check:types --watch\"",
"build": "pnpm run check:types && NODE_ENV=production tsup",
"release": "pnpm run build && np --no-2fa",
"test": "pnpm --filter @this/storybook run test",
"test:coverage": "pnpm run test --coverage && pnpm nyc report --reporter=lcov -t ./docs/storybook/coverage/storybook --report-dir ./docs/storybook/coverage/storybook",
"test:ci": "concurrently -k -s first -n \"SB,TEST\" -c \"magenta,blue\" \"pnpm run --filter @this/storybook storybook:build --quiet && pnpm http-server -a localhost ./docs/storybook/storybook-static --port 6006\" \"pnpm wait-port 6006 && pnpm run test:coverage\"",
"type:check": "tsc --noEmit",
"lint": "concurrently -k -s first -n \"eslint,prettier\" -c \"green,magenta\" \"pnpm run lint:eslint\" \"pnpm run lint:prettier\"",
"test:ci": "concurrently -k -s first -n \"SB,TEST\" -c \"magenta,blue\" \"pnpm run --filter @this/storybook storybook:build --quiet && pnpm sirv ./docs/storybook/storybook-static --host 127.0.0.1 --port 6006\" \"pnpm wait-port 6006 && pnpm run test:coverage\"",
"check:package": "pkg-ok",
"check:types": "tsc --noEmit",
"lint": "concurrently -n \"eslint,prettier\" -c \"green,magenta\" \"pnpm run lint:eslint\" \"pnpm run lint:prettier\"",
"lint:eslint": "eslint .",
"lint:prettier": "prettier --check .",
"lint-staged": "lint-staged",
Expand Down Expand Up @@ -101,15 +102,16 @@
"eslint": "^8.37.0",
"eslint-plugin-react": "^7.32.2",
"eslint-plugin-react-hooks": "^4.6.0",
"http-server": "^14.1.1",
"husky": "^8.0.3",
"lint-staged": "^13.2.0",
"np": "^7.7.0",
"nyc": "^15.1.0",
"pkg-ok": "^3.0.0",
"prettier": "^2.8.7",
"pretty-quick": "^3.1.3",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"sirv-cli": "^2.0.2",
"tslib": "~2.5.0",
"tsup": "^6.7.0",
"typescript": "5.0.3",
Expand Down

0 comments on commit e0ff502

Please sign in to comment.