@toptal/davinci-bootstrap 6.0.0 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -2
- package/README.md +1 -1
- package/docs/new.md +1 -1
- package/package.json +9 -9
- package/src/commands/new.js +3 -3
- package/src/utils/packages.js +4 -6
- package/src/utils/workspace.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 7.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- [#2643](https://github.com/toptal/davinci/pull/2643) [`ab9666f`](https://github.com/toptal/davinci/commit/ab9666f999e7a610f6068e0145200257d8511b46) Thanks [@rocodesign](https://github.com/rocodesign)!
|
|
8
|
+
Migrate package manager from Yarn to pnpm
|
|
9
|
+
**WHAT (breaking change):**
|
|
10
|
+
- switch package manager from Yarn to pnpm across the entire Davinci monorepo
|
|
11
|
+
- add `pnpm-workspace.yaml`, `.npmrc`, and `packageManager` field for corepack support
|
|
12
|
+
- convert Yarn `resolutions` to `pnpm.overrides` in root `package.json`
|
|
13
|
+
- update lerna `npmClient` from `yarn` to `pnpm`
|
|
14
|
+
- replace `yarn` with `pnpm` in root scripts (postinstall, test, test:unit:update)
|
|
15
|
+
**HOW to update:**
|
|
16
|
+
- install pnpm (`corepack enable` or `npm install -g pnpm@10.6.1`)
|
|
17
|
+
- replace `yarn install` with `pnpm install` in local workflows
|
|
18
|
+
- replace `yarn <script>` with `pnpm <script>` when running commands
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- Updated dependencies [[`ab9666f`](https://github.com/toptal/davinci/commit/ab9666f999e7a610f6068e0145200257d8511b46)]:
|
|
23
|
+
- @toptal/davinci-cli-shared@3.0.0
|
|
24
|
+
- @toptal/davinci-skeleton@15.0.0
|
|
25
|
+
- @toptal/davinci-workspace-root@2.0.0
|
|
26
|
+
|
|
3
27
|
## 6.0.0
|
|
4
28
|
|
|
5
29
|
### Major Changes
|
|
@@ -9,10 +33,10 @@
|
|
|
9
33
|
**WHAT (breaking change):**
|
|
10
34
|
- bootstrap now pins `tailwindcss` to `^3.3.5` so new apps don't accidentally install Tailwind v4, which is incompatible with the current PostCSS setup.
|
|
11
35
|
- skeleton's `tailwind.config.js` now includes `./node_modules/@toptal/picasso-*/**/*.js` in the `content` array so utility classes from all Picasso sub-packages (e.g. `@toptal/picasso-page`) are generated.
|
|
12
|
-
|
|
36
|
+
**WHY:**
|
|
13
37
|
- the skeleton's Tailwind `content` paths only covered `@toptal/picasso`, missing sub-packages like `@toptal/picasso-page` that use utility classes such as `flex-[1]`, `w-full`, and `justify-center`. Without scanning those files, Tailwind never generated the corresponding styles.
|
|
14
38
|
- without a pinned version, `davinci-bootstrap new` could install Tailwind v4, which drops the PostCSS plugin API used by the engine's `postcss-loader` configuration.
|
|
15
|
-
|
|
39
|
+
**HOW to update:**
|
|
16
40
|
- **new apps:** no action; new apps created with `davinci-bootstrap new` will get working Tailwind by default.
|
|
17
41
|
- **existing bootstrapped apps** where Tailwind classes don't generate: ensure `tailwindcss` is at `^3.3.5` and add `'./node_modules/@toptal/picasso-*/**/*.js'` to the `content` array in `tailwind.config.js`, then run `yarn install` and restart the dev server.
|
|
18
42
|
|
package/README.md
CHANGED
package/docs/new.md
CHANGED
|
@@ -6,7 +6,7 @@ davinci-bootstrap new <app name>
|
|
|
6
6
|
|
|
7
7
|
Creates a new app according to Toptal guidelines in directory `app-name` and
|
|
8
8
|
installs all dependencies (including `davinci` and `picasso`). Prepares app so
|
|
9
|
-
you can just run `
|
|
9
|
+
you can just run `pnpm start` and application will open in browser.
|
|
10
10
|
|
|
11
11
|
Arguments:
|
|
12
12
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toptal/davinci-bootstrap",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"cli",
|
|
6
6
|
"create-app",
|
|
@@ -23,22 +23,22 @@
|
|
|
23
23
|
"docs",
|
|
24
24
|
"CHANGELOG.md"
|
|
25
25
|
],
|
|
26
|
-
"scripts": {
|
|
27
|
-
"test": "NODE_OPTIONS='--experimental-vm-modules --no-warnings' yarn jest"
|
|
28
|
-
},
|
|
29
26
|
"dependencies": {
|
|
30
|
-
"@toptal/davinci-cli-shared": "^2.6.1",
|
|
31
|
-
"@toptal/davinci-skeleton": "^14.0.0",
|
|
32
|
-
"@toptal/davinci-workspace-root": "^1.0.1",
|
|
33
27
|
"execa": "^5.1.1",
|
|
34
28
|
"fs-extra": "^11.1.1",
|
|
35
29
|
"lodash.kebabcase": "^4.1.1",
|
|
36
|
-
"ora": "^5.4.1"
|
|
30
|
+
"ora": "^5.4.1",
|
|
31
|
+
"@toptal/davinci-cli-shared": "^3.0.0",
|
|
32
|
+
"@toptal/davinci-skeleton": "^15.0.0",
|
|
33
|
+
"@toptal/davinci-workspace-root": "^2.0.0"
|
|
37
34
|
},
|
|
38
35
|
"devDependencies": {
|
|
39
36
|
"@jest/globals": "^29.7.0"
|
|
40
37
|
},
|
|
41
38
|
"publishConfig": {
|
|
42
39
|
"access": "public"
|
|
40
|
+
},
|
|
41
|
+
"scripts": {
|
|
42
|
+
"test": "NODE_OPTIONS='--experimental-vm-modules --no-warnings' pnpm jest"
|
|
43
43
|
}
|
|
44
|
-
}
|
|
44
|
+
}
|
package/src/commands/new.js
CHANGED
|
@@ -65,6 +65,7 @@ const addVersionsToPackageJson = async (packageJson, destDir) => {
|
|
|
65
65
|
'@topkit/apollo-client',
|
|
66
66
|
'@toptal/picasso-tailwind',
|
|
67
67
|
'tailwindcss',
|
|
68
|
+
'@tailwindcss/postcss',
|
|
68
69
|
'react',
|
|
69
70
|
'react-dom',
|
|
70
71
|
'styled-components',
|
|
@@ -74,7 +75,6 @@ const addVersionsToPackageJson = async (packageJson, destDir) => {
|
|
|
74
75
|
|
|
75
76
|
const dependenciesFixedVersions = {
|
|
76
77
|
'@apollo/client': '^3.13.0',
|
|
77
|
-
tailwindcss: '^3.3.5',
|
|
78
78
|
}
|
|
79
79
|
|
|
80
80
|
const devDependencies = [
|
|
@@ -144,7 +144,7 @@ const installDependencies = async destDir => {
|
|
|
144
144
|
const spinner = ora('Installing dependencies... ').start()
|
|
145
145
|
|
|
146
146
|
try {
|
|
147
|
-
await run('
|
|
147
|
+
await run('pnpm', ['install', '--prefer-offline'], {
|
|
148
148
|
cwd: destDir,
|
|
149
149
|
})
|
|
150
150
|
spinner.succeed('Dependencies installed!')
|
|
@@ -169,7 +169,7 @@ const createCommand = async (appName, { skipInstall }) => {
|
|
|
169
169
|
// change package.json
|
|
170
170
|
await modifyPackageJson(destDir, appName)
|
|
171
171
|
|
|
172
|
-
// run
|
|
172
|
+
// run pnpm install
|
|
173
173
|
if (!skipInstall) {
|
|
174
174
|
await installDependencies(destDir)
|
|
175
175
|
}
|
package/src/utils/packages.js
CHANGED
|
@@ -13,14 +13,12 @@ export const findLatestVersionOfPackage = async (pkg, cwd) => {
|
|
|
13
13
|
return '18'
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
const result = await execa(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
{ cwd }
|
|
20
|
-
)
|
|
16
|
+
const result = await execa('pnpm', ['info', pkg, 'dist-tags', '--json'], {
|
|
17
|
+
cwd,
|
|
18
|
+
})
|
|
21
19
|
|
|
22
20
|
try {
|
|
23
|
-
const
|
|
21
|
+
const data = JSON.parse(result.stdout)
|
|
24
22
|
|
|
25
23
|
return data.latest
|
|
26
24
|
} catch (err) {
|
package/src/utils/workspace.js
CHANGED