Add babel plugin for nullish coalescing operator

This commit is contained in:
Max Goodhart
2020-08-24 00:51:14 -07:00
parent a7b5bb3d1b
commit 31516b4a22
3 changed files with 14 additions and 4 deletions

View File

@@ -2,6 +2,7 @@
"presets": ["@babel/preset-env"], "presets": ["@babel/preset-env"],
"plugins": [ "plugins": [
"@babel/plugin-proposal-optional-chaining", "@babel/plugin-proposal-optional-chaining",
"@babel/plugin-proposal-nullish-coalescing-operator",
"babel-plugin-styled-components", "babel-plugin-styled-components",
[ [
"@babel/plugin-transform-react-jsx", "@babel/plugin-transform-react-jsx",

16
package-lock.json generated
View File

@@ -400,13 +400,21 @@
} }
}, },
"@babel/plugin-proposal-nullish-coalescing-operator": { "@babel/plugin-proposal-nullish-coalescing-operator": {
"version": "7.10.1", "version": "7.10.4",
"resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.1.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.4.tgz",
"integrity": "sha512-56cI/uHYgL2C8HVuHOuvVowihhX0sxb3nnfVRzUeVHTWmRHTZrKuAh/OBIMggGU/S1g/1D2CRCXqP+3u7vX7iA==", "integrity": "sha512-wq5n1M3ZUlHl9sqT2ok1T2/MTt6AXE0e1Lz4WzWBr95LsAZ5qDXe4KnFuauYyEyLiohvXFMdbsOTMyLZs91Zlw==",
"dev": true, "dev": true,
"requires": { "requires": {
"@babel/helper-plugin-utils": "^7.10.1", "@babel/helper-plugin-utils": "^7.10.4",
"@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0" "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0"
},
"dependencies": {
"@babel/helper-plugin-utils": {
"version": "7.10.4",
"resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz",
"integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==",
"dev": true
}
} }
}, },
"@babel/plugin-proposal-numeric-separator": { "@babel/plugin-proposal-numeric-separator": {

View File

@@ -42,6 +42,7 @@
}, },
"devDependencies": { "devDependencies": {
"@babel/core": "^7.10.2", "@babel/core": "^7.10.2",
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.4",
"@babel/plugin-proposal-optional-chaining": "^7.10.1", "@babel/plugin-proposal-optional-chaining": "^7.10.1",
"@babel/plugin-transform-react-jsx": "^7.10.1", "@babel/plugin-transform-react-jsx": "^7.10.1",
"@babel/preset-env": "^7.10.2", "@babel/preset-env": "^7.10.2",