Skip to content

Commit

Permalink
fix: type definition issues related to pnpm hoisting rules in prepara…
Browse files Browse the repository at this point in the history
…tion for pnpm 7 upgrade (woocommerce#34154)

- added missing TS definition dependencies
  • Loading branch information
rjchow authored Aug 5, 2022
1 parent a397168 commit f3e436f
Show file tree
Hide file tree
Showing 22 changed files with 2,472 additions and 939 deletions.
2 changes: 2 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
; adding this as npm 7 automatically installs peer dependencies but pnpm does not
auto-install-peers=true
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
3 changes: 3 additions & 0 deletions packages/js/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,9 @@
"@testing-library/jest-dom": "^5.16.2",
"@testing-library/react": "^12.1.3",
"@testing-library/user-event": "^13.5.0",
"@types/wordpress__components": "^19.10.1",
"@types/wordpress__viewport": "^2.5.4",
"@types/react": "^17.0.0",
"@woocommerce/eslint-plugin": "workspace:*",
"@woocommerce/internal-style-build": "workspace:*",
"@wordpress/browserslist-config": "^4.1.1",
Expand All @@ -106,6 +108,7 @@
"jest": "^27.5.1",
"jest-cli": "^27.5.1",
"postcss-loader": "^3.0.0",
"react": "^17.0.0",
"rimraf": "^3.0.2",
"sass-loader": "^10.2.1",
"ts-jest": "^27.1.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/js/components/src/stepper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*/
import classnames from 'classnames';
import { createElement, Fragment } from '@wordpress/element';
import React from 'react';
import type React from 'react';

/**
* Internal dependencies
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
3 changes: 2 additions & 1 deletion packages/js/customer-effort-score/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@
"@babel/core": "^7.17.5",
"@testing-library/react": "^12.1.3",
"@types/prop-types": "^15.7.4",
"@types/wordpress__components": "^9.8.6",
"@types/wordpress__components": "^19.10.1",
"@types/wordpress__data": "^6.0.0",
"@woocommerce/eslint-plugin": "workspace:*",
"@woocommerce/internal-style-build": "workspace:*",
"@wordpress/browserslist-config": "^4.1.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
5 changes: 4 additions & 1 deletion packages/js/data/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@
"@types/wordpress__core-data": "^2.4.5",
"@types/wordpress__data": "^6.0.0",
"@types/wordpress__data-controls": "^2.2.0",
"@types/react": "^17.0.0",
"@types/lodash": "^4.14.182",
"@types/qs": "^6.9.7",
"@woocommerce/eslint-plugin": "workspace:*",
"eslint": "^8.12.0",
"jest": "^27.5.1",
Expand Down Expand Up @@ -88,4 +91,4 @@
"pnpm test-staged"
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
2 changes: 2 additions & 0 deletions packages/js/date/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
"devDependencies": {
"@babel/core": "^7.17.5",
"@woocommerce/eslint-plugin": "workspace:*",
"@types/lodash": "^4.14.182",
"@types/qs": "^6.9.7",
"d3-time-format": "^2.3.0",
"eslint": "^8.12.0",
"jest": "^27.5.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
1 change: 1 addition & 0 deletions packages/js/experimental/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
"@testing-library/user-event": "^13.5.0",
"@types/dompurify": "^2.3.3",
"@types/react-transition-group": "^4.4.4",
"@types/wordpress__components": "^19.10.1",
"@woocommerce/eslint-plugin": "workspace:*",
"@woocommerce/internal-style-build": "workspace:*",
"@wordpress/browserslist-config": "^4.1.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
1 change: 1 addition & 0 deletions packages/js/explat/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
"@babel/core": "^7.17.5",
"@types/cookie": "^0.4.1",
"@types/node": "^17.0.21",
"@types/react": "^17.0.0",
"@types/qs": "^6.9.7",
"@woocommerce/eslint-plugin": "workspace:*",
"eslint": "^8.12.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
2 changes: 2 additions & 0 deletions packages/js/navigation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
"@wordpress/notices": "^3.3.2",
"@wordpress/url": "^3.4.1",
"history": "^5.3.0",
"react-router-dom": "^6.3.0",
"qs": "^6.10.3"
},
"peerDependencies": {
Expand Down Expand Up @@ -57,6 +58,7 @@
"@babel/runtime": "^7.17.2",
"@woocommerce/eslint-plugin": "workspace:*",
"eslint": "^8.12.0",
"@types/qs": "^6.9.7",
"jest": "^27.5.1",
"jest-cli": "^27.5.1",
"rimraf": "^3.0.2",
Expand Down
3 changes: 3 additions & 0 deletions packages/js/notices/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@
"@automattic/data-stores": "^2.0.1",
"@babel/core": "^7.17.5",
"@woocommerce/eslint-plugin": "workspace:*",
"@types/lodash": "^4.14.182",
"@types/wordpress__notices": "^3.5.0",
"@types/wordpress__data": "^6.0.0",
"eslint": "^8.12.0",
"jest": "^27.5.1",
"jest-cli": "^27.5.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fix

Added in missing TS definitions in package.json
1 change: 1 addition & 0 deletions packages/js/onboarding/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
"@woocommerce/eslint-plugin": "workspace:*",
"@woocommerce/internal-style-build": "workspace:*",
"@wordpress/browserslist-config": "^4.1.1",
"@types/wordpress__components": "^19.10.1",
"css-loader": "^3.6.0",
"eslint": "^8.12.0",
"jest": "^27.5.1",
Expand Down
6 changes: 4 additions & 2 deletions plugins/woocommerce-admin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -117,15 +117,17 @@
"@types/jest": "^27.4.1",
"@types/lodash": "^4.14.179",
"@types/puppeteer": "^4.0.2",
"@types/react": "^17.0.0",
"@types/react-router-dom": "^5.3.3",
"@types/react-transition-group": "^4.4.4",
"@types/testing-library__jest-dom": "^5.14.3",
"@types/wordpress__components": "^19.3.0",
"@types/wordpress__components": "^19.10.1",
"@types/wordpress__compose": "^4.0.1",
"@types/wordpress__data": "^6.0.0",
"@types/wordpress__data-controls": "^2.2.0",
"@types/wordpress__notices": "^3.3.0",
"@types/wordpress__plugins": "^3.0.0",
"@types/qs": "^6.9.7",
"@typescript-eslint/eslint-plugin": "^5.14.0",
"@typescript-eslint/parser": "^5.14.0",
"@woocommerce/admin-e2e-tests": "workspace:*",
Expand Down Expand Up @@ -228,4 +230,4 @@
"node": "^16.13.1",
"pnpm": "^6.24.2"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: minor
Type: fix

Minor changes to address Typescript errors after updating TS definitions
Loading

0 comments on commit f3e436f

Please sign in to comment.