-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*: switch to pnpm #527
*: switch to pnpm #527
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,18 +2,15 @@ | |
"name": "root", | ||
"private": true, | ||
"devDependencies": { | ||
"auto": "10.43.0", | ||
"lerna": "5.6.2" | ||
"auto": "11.0.4", | ||
"lerna": "^7.2.0" | ||
}, | ||
"scripts": { | ||
"init": "yarn install && yarn lerna run build", | ||
"start": "lerna run start --parallel", | ||
"start": "pnpm run --recursive --parallel start", | ||
"test": "pnpm run --recursive test", | ||
"build": "pnpm run --recursive build", | ||
"release": "auto shipit" | ||
}, | ||
"resolutions": {}, | ||
"workspaces": [ | ||
"packages/*" | ||
], | ||
"repository": "cockroachdb/ui", | ||
"author": "Cockroach Labs <[email protected]>", | ||
"auto": { | ||
|
@@ -48,5 +45,11 @@ | |
"changelogTitle": "📝 Documentation" | ||
} | ||
] | ||
}, | ||
"pnpm": { | ||
"overrides": { | ||
"@types/react-lines-ellipsis>@types/react": "17", | ||
"@types/recharts>@types/react": "17" | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,7 @@ | |
"types": "dist/web/tokens.d.ts", | ||
"scripts": { | ||
"build": "style-dictionary build", | ||
"clean": "style-dictionary clean", | ||
"prepare": "npm run clean && npm run build", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Something about the "automatically build after running There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That's fair. I never could get the right feel for the correct life-cycle script here. I think I had "prepublishOnly" at one point but it may have been deprecated. This becomes a lot less critical with auto-publishing where we don't need lifecycle scripts to help us remember to "build" before we "publish". |
||
"test": "echo \"Error: no test specified\" && exit 1" | ||
"clean": "style-dictionary clean" | ||
}, | ||
"license": "MIT", | ||
"devDependencies": { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,15 +8,14 @@ | |
"main": "dist/index.js", | ||
"types": "dist/index.d.ts", | ||
"scripts": { | ||
"build": "npm run build:generate:stripfill && npm run build:generate:preserve && npm run build:typescript", | ||
"build": "run-s build:generate:stripfill build:generate:preserve build:typescript", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ooo. What is There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Unfortunately it's an alias that comes wioth |
||
"build:typescript": "tsc", | ||
"build:generate:stripfill": "svgr --typescript --icon -d src/components svg/customFill", | ||
"build:generate:preserve": "svgr --typescript --icon --no-runtime-config -d src/components svg/preserveFill", | ||
"build:watch": "tsc --watch", | ||
"build:watch": "tsc --watch --preserveWatchOutput", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Without this, |
||
"clean": "rimraf dist src/components", | ||
"prepare": "npm run clean && npm run build", | ||
"test": "node notests.js", | ||
"start": "npm run build:watch" | ||
"start": "pnpm run build:watch" | ||
}, | ||
"license": "MIT", | ||
"devDependencies": { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,8 +18,8 @@ | |
}, | ||
"homepage": "https://github.com/cockroachdb/ui#readme", | ||
"dependencies": { | ||
"@cockroachlabs/icons": "^0.7.6", | ||
"@cockroachlabs/ui-components": "^0.7.7", | ||
"@cockroachlabs/icons": "workspace:../icons", | ||
"@cockroachlabs/ui-components": "workspace:../ui-components", | ||
Comment on lines
+21
to
+22
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. hooray There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a huge improvement honestly. I haven't gotten there yet, but any idea how this will be handled when building storybook for deployment? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It shouuuuuuuld automatically link everything together :) |
||
"ts-loader": "9.4.2", | ||
"typescript": "4.8.4" | ||
}, | ||
|
@@ -42,8 +42,5 @@ | |
"storybook": "7.0.20", | ||
"ts-loader": "9.4.2", | ||
"webpack": "5.75.0" | ||
}, | ||
"resolutions": { | ||
"prismjs": "^1.21.0" | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,27 +9,27 @@ | |
"main": "dist/main.js", | ||
"types": "dist/types/index.d.ts", | ||
"scripts": { | ||
"build": "npm run build:typescript && npm run build:bundle", | ||
"build": "npm-run-all build:typescript build:bundle", | ||
"build:bundle": "webpack --mode production", | ||
"build:typescript": "tsc", | ||
"build:watch": "webpack --mode development --watch", | ||
"ci": "jest --ci -i", | ||
"clean": "rm -rf ./dist/*", | ||
"lint": "eslint \"src/**/*.{tsx,ts,js}\"", | ||
"lint:fix": "eslint \"src/**/*.{tsx,ts,js}\" --fix", | ||
"prepare": "npm run clean && npm run build", | ||
"test": "jest --watch", | ||
"test:version": "npm version prerelease --preid='alpha'", | ||
"test:publish": "npm publish --tag testing", | ||
"test": "jest", | ||
"test:watch": "jest --watch", | ||
"test:version": "pnpm version prerelease --preid='alpha'", | ||
"test:publish": "pnpm publish --tag testing", | ||
"publish-test-version": "npm-run-all test:version test:publish", | ||
"start": "npm run build:watch" | ||
"start": "pnpm run build:watch" | ||
}, | ||
"keywords": [], | ||
"license": "MIT", | ||
"dependencies": { | ||
"@cockroachlabs/icons": "^0.7.6", | ||
"@cockroachlabs/icons": "workspace:../icons", | ||
"@popperjs/core": "^2.9.2", | ||
"@types/recharts": "^1.8.23", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was never a runtime dependency — moved to dev dependencies |
||
"lodash": "^4.17.21", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Accidentally-missing dependency (previously hoisted from another package) |
||
"react-lines-ellipsis": "^0.15.0", | ||
"react-popper": "^2.2.5", | ||
"recharts": "^2.1.12" | ||
|
@@ -42,8 +42,8 @@ | |
"@babel/preset-env": "7.20.2", | ||
"@babel/preset-react": "7.18.6", | ||
"@babel/preset-typescript": "7.21.0", | ||
"@cockroachlabs/design-tokens": "^0.4.12", | ||
"@cockroachlabs/eslint-config": "^1.0.5", | ||
"@cockroachlabs/design-tokens": "workspace:../design-tokens", | ||
"@cockroachlabs/eslint-config": "workspace:../eslint-config", | ||
"@testing-library/jest-dom": "5.16.5", | ||
"@testing-library/react": "12.1.5", | ||
"@types/classnames": "2.3.0", | ||
|
@@ -52,6 +52,8 @@ | |
"@types/node": "16.18.14", | ||
"@types/react": "17.0.53", | ||
"@types/react-lines-ellipsis": "0.15.1", | ||
"@types/recharts": "^1.8.23", | ||
"@types/testing-library__jest-dom": "^5.14.6", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Accidentally-missing dependency (previously provided by |
||
"@typescript-eslint/eslint-plugin": "5.54.0", | ||
"@typescript-eslint/parser": "5.54.0", | ||
"babel-loader": "8.3.0", | ||
|
@@ -68,6 +70,7 @@ | |
"jest-environment-jsdom": "29.4.3", | ||
"jest-runner-eslint": "1.1.0", | ||
"mini-css-extract-plugin": "^2.7.5", | ||
"npm-run-all": "4.1.5", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Accidentally missing dependency (got hoisted from another package) |
||
"prettier": "2.8.4", | ||
"react": "17.0.2", | ||
"react-dom": "17.0.2", | ||
|
@@ -86,6 +89,5 @@ | |
"react": "^17.0.2", | ||
"react-dom": "^17.0.2" | ||
}, | ||
"resolutions": {}, | ||
"gitHead": "a77405daccfaf2d38cc08ef7c322172ee93776fd" | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
/* eslint-disable @typescript-eslint/no-var-requires */ | ||
/* globals module, __dirname */ | ||
const path = require("path"); | ||
const WebpackBar = require("webpackbar"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It got in the way of watch task reporting and spewed way too many lines. I can put it back if we want, but 🤷 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nah, this was something I was playing with way back in the beginning. It was only something to clean up the output of watching only |
||
const MiniCssExtractPlugin = require("mini-css-extract-plugin"); | ||
|
||
module.exports = { | ||
|
@@ -55,11 +54,6 @@ module.exports = { | |
|
||
plugins: [ | ||
new MiniCssExtractPlugin(), | ||
new WebpackBar({ | ||
name: "ui-components", | ||
color: "cyan", | ||
profile: true, | ||
}), | ||
], | ||
|
||
// When importing a module whose path matches one of the following, just | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The output for these is actually really nice!