chore: switch to pnpm

This commit is contained in:
Nolan Lawson 2024-03-23 10:27:03 -07:00
parent f90b550743
commit 6702802566
9 changed files with 7828 additions and 10491 deletions

View File

@ -19,16 +19,15 @@ jobs:
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'yarn'
- run: yarn install --immutable
- run: yarn build
cache: 'pnpm'
- run: pnpm i --frozen-lockfile
- name: install chromedriver
run: |
# install the chromedriver corresponding to whatever version of chrome is installed
npm i -g chromedriver@^$(google-chrome --version | awk '{print $3}' | cut -d. -f1)
PERF=1 yarn build:rollup
yarn benchmark:runtime:setup
pnpm i chromedriver@^$(google-chrome --version | awk '{print $3}' | cut -d. -f1)
PERF=1 pnpm build:rollup
pnpm benchmark:runtime:setup
# first-load
- name: Benchmark first-load

View File

@ -13,9 +13,8 @@ jobs:
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'yarn'
- run: yarn install --immutable
- run: yarn build
cache: 'pnpm'
- run: pnpm i --frozen-lockfile
- uses: preactjs/compressed-size-action@v2
with:
build-script: benchmark:bundle

View File

@ -13,11 +13,10 @@ jobs:
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'yarn'
- run: yarn install --immutable
- run: yarn build
cache: 'pnpm'
- run: pnpm i --frozen-lockfile
- run: sudo apt-get install fonts-noto-color-emoji
- run: yarn lint
- run: yarn benchmark:bundlesize
- run: yarn cover
- run: yarn test:leak
- run: pnpm lint
- run: pnpm benchmark:bundlesize
- run: pnpm cover
- run: pnpm test:leak

9
.gitignore vendored
View File

@ -127,12 +127,3 @@ dist
/test/benchmark/picker.js
/test/benchmark/*.tachometer.json
/i18n
# yarn v2+
.yarn/*
!.yarn/cache
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions

View File

@ -38,8 +38,8 @@ for (const benchmark of benchmarks) {
repo: 'https://github.com/nolanlawson/emoji-picker-element.git',
ref: 'master',
setupCommands: [
'yarn --immutable --ignore-scripts',
'PERF=1 yarn build:rollup'
'pnpm --frozen-lockfile',
'PERF=1 pnpm build:rollup'
]
}
}

View File

@ -185,9 +185,5 @@
"*.js": "standard --fix",
"*.(css|scss)": "stylelint --fix '**/*.scss'"
},
"volta": {
"node": "20.11.1",
"yarn": "4.1.1"
},
"packageManager": "yarn@4.1.1"
"packageManager": "pnpm@8.15.5+sha256.4b4efa12490e5055d59b9b9fc9438b7d581a6b7af3b5675eb5c5f447cee1a589"
}

7811
pnpm-lock.yaml Normal file

File diff suppressed because it is too large Load Diff

View File

@ -29,7 +29,7 @@ async function doFullDatabaseScanForSingleResult (db, predicate) {
//
// Mini-benchmark for determining the best batch size:
//
// PERF=1 yarn build:rollup && yarn test:adhoc
// PERF=1 pnpm build:rollup && pnpm test:adhoc
//
// (async () => {
// performance.mark('start')

10458
yarn.lock

File diff suppressed because it is too large Load Diff