Skip to content

Commit

Permalink
chore(deps): update dependency camelcase to v8 (#15245)
Browse files Browse the repository at this point in the history
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: fisker <lionkay@gmail.com>
  • Loading branch information
renovate[bot] and fisker committed Aug 15, 2023
1 parent f24132e commit 91e850b
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"acorn-jsx": "5.3.2",
"angular-estree-parser": "7.0.0",
"angular-html-parser": "4.0.1",
"camelcase": "7.0.1",
"camelcase": "8.0.0",
"chalk": "5.3.0",
"ci-info": "3.8.0",
"cjk-regex": "3.0.0",
Expand Down
2 changes: 1 addition & 1 deletion scripts/build/build-javascript-module.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ function getEsbuildOptions({ file, files, shouldCollectLicenses, cliOptions }) {
find: "const __dirname = path.dirname(fileURLToPath(import.meta.url));",
replacement: "",
},
// Transform `.at` and `Object.hasOwn`
// Transform `.at`, `Object.hasOwn`, and `String#replaceAll`
{
module: "*",
process: transform,
Expand Down
8 changes: 6 additions & 2 deletions scripts/build/transform/index.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
import path from "node:path";
import { parse } from "@babel/parser";
import { traverseFast as traverse } from "@babel/types";
import babelGenerator from "@babel/generator";
import { outdent } from "outdent";
import { SOURCE_DIR } from "../../utils/index.js";
import { SOURCE_DIR, PROJECT_ROOT } from "../../utils/index.js";
import allTransforms from "./transforms/index.js";

const generate = babelGenerator.default;

/* Doesn't work for dependencies, optional call, computed property, and spread arguments */

function transform(original, file) {
if (!file.startsWith(SOURCE_DIR)) {
if (
!file.startsWith(SOURCE_DIR) &&
!file.startsWith(path.join(PROJECT_ROOT, "node_modules/camelcase/"))
) {
return original;
}

Expand Down
10 changes: 5 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2550,10 +2550,10 @@ __metadata:
languageName: node
linkType: hard

"camelcase@npm:7.0.1":
version: 7.0.1
resolution: "camelcase@npm:7.0.1"
checksum: 86ab8f3ebf08bcdbe605a211a242f00ed30d8bfb77dab4ebb744dd36efbc84432d1c4adb28975ba87a1b8be40a80fbd1e60e2f06565315918fa7350011a26d3d
"camelcase@npm:8.0.0":
version: 8.0.0
resolution: "camelcase@npm:8.0.0"
checksum: 6da7abe997af29e80052f17aa21628c7cce14af364cef9f07a2a44d59614dd6f361d405f121938e673424d673697a8c53ad17be8c4b03b0a727307c4db8b5b5e
languageName: node
linkType: hard

Expand Down Expand Up @@ -7028,7 +7028,7 @@ __metadata:
benchmark: 2.1.4
browserslist-to-esbuild: 1.2.0
c8: 8.0.1
camelcase: 7.0.1
camelcase: 8.0.0
chalk: 5.3.0
ci-info: 3.8.0
cjk-regex: 3.0.0
Expand Down

0 comments on commit 91e850b

Please sign in to comment.