Skip to content

Commit 7b6253e

Browse files
committed
chore: simplify Babel configuration
1 parent bb7af9a commit 7b6253e

File tree

3 files changed

+386
-1049
lines changed

3 files changed

+386
-1049
lines changed

babel.config.js

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,4 @@
11
module.exports = {
2-
presets: [
3-
[
4-
'@babel/preset-env',
5-
{
6-
targets: {
7-
esmodules: true
8-
}
9-
}
10-
],
11-
'@babel/preset-typescript',
12-
'@babel/preset-react'
13-
],
14-
plugins: [
15-
['@babel/plugin-proposal-decorators', { legacy: true }],
16-
'@babel/plugin-proposal-optional-chaining',
17-
'@babel/plugin-proposal-class-properties',
18-
'@babel/plugin-proposal-object-rest-spread'
19-
]
2+
presets: ['@babel/preset-typescript', '@babel/preset-react'],
3+
plugins: ['@babel/plugin-transform-modules-commonjs']
204
};

package.json

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,9 @@
2424
},
2525
"homepage": "https://github.com/patternfly/patternfly-react#readme",
2626
"devDependencies": {
27-
"@babel/core": "^7.21.8",
28-
"@babel/plugin-proposal-class-properties": "^7.18.6",
29-
"@babel/plugin-proposal-decorators": "^7.21.0",
30-
"@babel/plugin-proposal-object-rest-spread": "^7.20.7",
31-
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
32-
"@babel/plugin-proposal-private-methods": "^7.18.6",
33-
"@babel/plugin-proposal-private-property-in-object": "^7.21.0",
34-
"@babel/preset-env": "^7.21.5",
35-
"@babel/preset-react": "^7.18.6",
36-
"@babel/preset-typescript": "^7.21.5",
27+
"@babel/plugin-transform-modules-commonjs": "^7.24.1",
28+
"@babel/preset-react": "^7.24.1",
29+
"@babel/preset-typescript": "^7.24.1",
3730
"@octokit/rest": "^20.0.0",
3831
"@testing-library/jest-dom": "^5.16.5",
3932
"@testing-library/react": "^13.4.0",
@@ -43,8 +36,7 @@
4336
"@types/react-dom": "^18",
4437
"@typescript-eslint/eslint-plugin": "^5.59.2",
4538
"@typescript-eslint/parser": "^5.59.2",
46-
"babel-jest": "^27.2.5",
47-
"jest-transform-stub": "^2.0.0",
39+
"babel-jest": "^29.7.0",
4840
"concurrently": "^7.6.0",
4941
"eslint": "^8.39.0",
5042
"eslint-plugin-markdown": "^3.0.0",
@@ -56,6 +48,7 @@
5648
"husky": "^4.3.0",
5749
"jest": "27.2.5",
5850
"jest-cli": "27.2.5",
51+
"jest-transform-stub": "^2.0.0",
5952
"lerna": "^7.1.5",
6053
"lint-staged": "^14.0.0",
6154
"mutation-observer": "^1.0.3",
@@ -64,9 +57,9 @@
6457
"react": "^18",
6558
"react-dom": "^18",
6659
"surge": "^0.23.1",
60+
"ts-node": "^10.9.1",
6761
"ts-patch": "^2.1.0",
68-
"typescript": "^4.7.4",
69-
"ts-node": "^10.9.1"
62+
"typescript": "^4.7.4"
7063
},
7164
"scripts": {
7265
"build": "yarn clean && yarn build:generate && yarn build:esm && yarn build:cjs && yarn build:subpaths && yarn build:single:packages",

0 commit comments

Comments
 (0)