diff --git a/CHANGELOG.md b/CHANGELOG.md index a48dc83688..3f39e61af3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,11 +13,15 @@ Our versioning strategy is as follows: ### ๐Ÿ›  Breaking Changes -[sitecore-jss] Switch to edge site query for XP and gets config sites + sxa sites (ignoring website) +* [sitecore-jss] Switch to edge site query for XP and gets config sites + sxa sites (ignoring website) * Previously introduced Boolean `useSiteQuery` switch for XMCloud users has been removed. * Search query usage has been removed. * If you have any non-nextjs sites they should filter them out in multisite config plugin +### ๐Ÿงน Chores + +* Security vulnerabilities audit ([1778](https://github.com/Sitecore/jss/pull/1778)) + ## 21.7.1 ### ๐Ÿ› Bug Fixes diff --git a/packages/create-sitecore-jss/src/templates/node-headless-ssr-proxy/package.json b/packages/create-sitecore-jss/src/templates/node-headless-ssr-proxy/package.json index 1747bda112..1335ca02ce 100644 --- a/packages/create-sitecore-jss/src/templates/node-headless-ssr-proxy/package.json +++ b/packages/create-sitecore-jss/src/templates/node-headless-ssr-proxy/package.json @@ -23,7 +23,7 @@ "@sitecore-jss/sitecore-jss-proxy": "~21.8.0-canary", "agentkeepalive": "^4.2.1", "compression": "~1.7.4", - "express": "~4.18.2", + "express": "~4.19.2", "memory-cache": "^0.2.0", "dotenv": "^16.0.3" }, diff --git a/packages/sitecore-jss-dev-tools/.vscode/launch.json b/packages/sitecore-jss-dev-tools/.vscode/launch.json index b82601ecb7..a864267aa8 100644 --- a/packages/sitecore-jss-dev-tools/.vscode/launch.json +++ b/packages/sitecore-jss-dev-tools/.vscode/launch.json @@ -1,21 +1,21 @@ -{ - "version": "0.2.0", - "configurations": [ - { - "name": "Run mocha", - "type": "node2", - "request": "launch", - "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", - "stopOnEntry": false, - "args": [ - "--compilers", - "js:babel-core/register", - "./src/**/*.test.js", - "--no-timeouts", - "./dist/test" - ], - "cwd": "${workspaceRoot}", - "runtimeExecutable": null - } - ] +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Run mocha", + "type": "node", + "request": "launch", + "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", + "stopOnEntry": false, + "args": [ + "--require", + "@babel/register", + "./src/**/*.test.js", + "--no-timeouts", + "./dist/test" + ], + "cwd": "${workspaceRoot}", + "runtimeExecutable": null + } + ] } \ No newline at end of file diff --git a/packages/sitecore-jss-dev-tools/package.json b/packages/sitecore-jss-dev-tools/package.json index 125dea40ce..1505a04639 100644 --- a/packages/sitecore-jss-dev-tools/package.json +++ b/packages/sitecore-jss-dev-tools/package.json @@ -56,6 +56,8 @@ "yargs": "^17.6.2" }, "devDependencies": { + "@babel/core": "^7.24.4", + "@babel/register": "^7.23.7", "@types/chai": "^4.3.4", "@types/chokidar": "^2.1.3", "@types/del": "^4.0.0", @@ -71,7 +73,6 @@ "@types/url-join": "^4.0.1", "@types/uuid": "^9.0.0", "@types/yargs": "^17.0.22", - "babel-core": "^6.26.3", "chai": "^4.3.7", "cross-env": "^7.0.3", "del-cli": "^5.0.0", diff --git a/packages/sitecore-jss-dev-tools/src/pipelines/runner.ts b/packages/sitecore-jss-dev-tools/src/pipelines/runner.ts index d4a04854cf..8d249e5d63 100644 --- a/packages/sitecore-jss-dev-tools/src/pipelines/runner.ts +++ b/packages/sitecore-jss-dev-tools/src/pipelines/runner.ts @@ -14,7 +14,7 @@ pipeline.addProcessor({ }); pipeline - .runWithCompilers(['babel-core/register']) + .runWithCompilers(['@babel/register']) .then((result) => { console.log(JSON.stringify(result, null, 2)); }) @@ -23,7 +23,7 @@ pipeline }); const runner = async () => { - const compilers = ['babel-core/register']; + const compilers = ['@babel/register']; return initCompilers(compilers) .then(() => configLoader({ fileGlobs: ['../test/pipelines/**/*.config.js'], workingDirectory: __dirname }) diff --git a/packages/sitecore-jss-vue/package.json b/packages/sitecore-jss-vue/package.json index 61d53751ec..2ca499d3f7 100644 --- a/packages/sitecore-jss-vue/package.json +++ b/packages/sitecore-jss-vue/package.json @@ -27,13 +27,11 @@ "url": "https://github.com/sitecore/jss/issues" }, "devDependencies": { - "@babel/core": "^7.20.12", "@types/jest": "^29.2.6", "@types/node": "^18.11.18", "@vue/compiler-dom": "^3.2.45", "@vue/test-utils": "2.2.7", "@vue/vue3-jest": "^29.2.2", - "babel-core": "^6.26.3", "babel-jest": "^29.5.0", "del-cli": "^5.0.0", "eslint": "^8.32.0", diff --git a/yarn.lock b/yarn.lock index 03b46fa192..4ccce4aacb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -423,6 +423,16 @@ __metadata: languageName: node linkType: hard +"@babel/code-frame@npm:^7.24.1, @babel/code-frame@npm:^7.24.2": + version: 7.24.2 + resolution: "@babel/code-frame@npm:7.24.2" + dependencies: + "@babel/highlight": ^7.24.2 + picocolors: ^1.0.0 + checksum: 70e867340cfe09ca5488b2f36372c45cabf43c79a5b6426e6df5ef0611ff5dfa75a57dda841895693de6008f32c21a7c97027a8c7bcabd63a7d17416cbead6f8 + languageName: node + linkType: hard + "@babel/compat-data@npm:^7.20.5, @babel/compat-data@npm:^7.22.6, @babel/compat-data@npm:^7.22.9, @babel/compat-data@npm:^7.23.3, @babel/compat-data@npm:^7.23.5": version: 7.23.5 resolution: "@babel/compat-data@npm:7.23.5" @@ -476,7 +486,7 @@ __metadata: languageName: node linkType: hard -"@babel/core@npm:^7.0.0, @babel/core@npm:^7.1.0, @babel/core@npm:^7.11.6, @babel/core@npm:^7.12.3, @babel/core@npm:^7.20.12, @babel/core@npm:^7.6.2, @babel/core@npm:^7.7.5": +"@babel/core@npm:^7.0.0, @babel/core@npm:^7.1.0, @babel/core@npm:^7.11.6, @babel/core@npm:^7.12.3, @babel/core@npm:^7.6.2, @babel/core@npm:^7.7.5": version: 7.23.6 resolution: "@babel/core@npm:7.23.6" dependencies: @@ -499,6 +509,29 @@ __metadata: languageName: node linkType: hard +"@babel/core@npm:^7.24.4": + version: 7.24.4 + resolution: "@babel/core@npm:7.24.4" + dependencies: + "@ampproject/remapping": ^2.2.0 + "@babel/code-frame": ^7.24.2 + "@babel/generator": ^7.24.4 + "@babel/helper-compilation-targets": ^7.23.6 + "@babel/helper-module-transforms": ^7.23.3 + "@babel/helpers": ^7.24.4 + "@babel/parser": ^7.24.4 + "@babel/template": ^7.24.0 + "@babel/traverse": ^7.24.1 + "@babel/types": ^7.24.0 + convert-source-map: ^2.0.0 + debug: ^4.1.0 + gensync: ^1.0.0-beta.2 + json5: ^2.2.3 + semver: ^6.3.1 + checksum: 15ecad7581f3329995956ba461961b1af7bed48901f14fe962ccd3217edca60049e9e6ad4ce48134618397e6c90230168c842e2c28e47ef1f16c97dbbf663c61 + languageName: node + linkType: hard + "@babel/generator@npm:7.22.9": version: 7.22.9 resolution: "@babel/generator@npm:7.22.9" @@ -523,6 +556,18 @@ __metadata: languageName: node linkType: hard +"@babel/generator@npm:^7.24.1, @babel/generator@npm:^7.24.4": + version: 7.24.4 + resolution: "@babel/generator@npm:7.24.4" + dependencies: + "@babel/types": ^7.24.0 + "@jridgewell/gen-mapping": ^0.3.5 + "@jridgewell/trace-mapping": ^0.3.25 + jsesc: ^2.5.1 + checksum: 1b6146c31386c9df3eb594a2c36b5c98da4f67f7c06edb3d68a442b92516b21bb5ba3ad7dbe0058fe76625ed24d66923e15c95b0df75ef1907d4068921a699b8 + languageName: node + linkType: hard + "@babel/helper-annotate-as-pure@npm:7.22.5, @babel/helper-annotate-as-pure@npm:^7.22.5": version: 7.22.5 resolution: "@babel/helper-annotate-as-pure@npm:7.22.5" @@ -772,6 +817,17 @@ __metadata: languageName: node linkType: hard +"@babel/helpers@npm:^7.24.4": + version: 7.24.4 + resolution: "@babel/helpers@npm:7.24.4" + dependencies: + "@babel/template": ^7.24.0 + "@babel/traverse": ^7.24.1 + "@babel/types": ^7.24.0 + checksum: ecd2dc0b3b32e24b97fa3bcda432dd3235b77c2be1e16eafc35b8ef8f6c461faa99796a8bc2431a408c98b4aabfd572c160e2b67ecea4c5c9dd3a8314a97994a + languageName: node + linkType: hard + "@babel/highlight@npm:^7.10.4, @babel/highlight@npm:^7.23.4": version: 7.23.4 resolution: "@babel/highlight@npm:7.23.4" @@ -783,6 +839,18 @@ __metadata: languageName: node linkType: hard +"@babel/highlight@npm:^7.24.2": + version: 7.24.2 + resolution: "@babel/highlight@npm:7.24.2" + dependencies: + "@babel/helper-validator-identifier": ^7.22.20 + chalk: ^2.4.2 + js-tokens: ^4.0.0 + picocolors: ^1.0.0 + checksum: 5f17b131cc3ebf3ab285a62cf98a404aef1bd71a6be045e748f8d5bf66d6a6e1aefd62f5972c84369472e8d9f22a614c58a89cd331eb60b7ba965b31b1bbeaf5 + languageName: node + linkType: hard + "@babel/parser@npm:^7.0.0, @babel/parser@npm:^7.1.0, @babel/parser@npm:^7.14.7, @babel/parser@npm:^7.20.7, @babel/parser@npm:^7.22.15, @babel/parser@npm:^7.22.5, @babel/parser@npm:^7.22.7, @babel/parser@npm:^7.23.0, @babel/parser@npm:^7.23.5, @babel/parser@npm:^7.23.6, @babel/parser@npm:^7.4.3": version: 7.23.6 resolution: "@babel/parser@npm:7.23.6" @@ -801,6 +869,15 @@ __metadata: languageName: node linkType: hard +"@babel/parser@npm:^7.24.1, @babel/parser@npm:^7.24.4": + version: 7.24.4 + resolution: "@babel/parser@npm:7.24.4" + bin: + parser: ./bin/babel-parser.js + checksum: 94c9e3e592894cd6fc57c519f4e06b65463df9be5f01739bb0d0bfce7ffcf99b3c2fdadd44dc59cc858ba2739ce6e469813a941c2f2dfacf333a3b2c9c5c8465 + languageName: node + linkType: hard + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@npm:^7.22.5, @babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@npm:7.23.3" @@ -2162,6 +2239,21 @@ __metadata: languageName: node linkType: hard +"@babel/register@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/register@npm:7.23.7" + dependencies: + clone-deep: ^4.0.1 + find-cache-dir: ^2.0.0 + make-dir: ^2.1.0 + pirates: ^4.0.6 + source-map-support: ^0.5.16 + peerDependencies: + "@babel/core": ^7.0.0-0 + checksum: c72a6d4856ef04f13490370d805854d2d98a77786bfaec7d85e2c585e1217011c4f3df18197a890e14520906c9111bef95551ba1a9b59c88df4dfc2dfe2c8d1b + languageName: node + linkType: hard + "@babel/regjsgen@npm:^0.8.0": version: 0.8.0 resolution: "@babel/regjsgen@npm:0.8.0" @@ -2209,6 +2301,17 @@ __metadata: languageName: node linkType: hard +"@babel/template@npm:^7.24.0": + version: 7.24.0 + resolution: "@babel/template@npm:7.24.0" + dependencies: + "@babel/code-frame": ^7.23.5 + "@babel/parser": ^7.24.0 + "@babel/types": ^7.24.0 + checksum: f257b003c071a0cecdbfceca74185f18fe62c055469ab5c1d481aab12abeebed328e67e0a19fd978a2a8de97b28953fa4bc3da6d038a7345fdf37923b9fcdec8 + languageName: node + linkType: hard + "@babel/traverse@npm:^7.0.0, @babel/traverse@npm:^7.1.0, @babel/traverse@npm:^7.22.8, @babel/traverse@npm:^7.23.2, @babel/traverse@npm:^7.23.6, @babel/traverse@npm:^7.4.3, @babel/traverse@npm:^7.7.4": version: 7.23.6 resolution: "@babel/traverse@npm:7.23.6" @@ -2227,6 +2330,24 @@ __metadata: languageName: node linkType: hard +"@babel/traverse@npm:^7.24.1": + version: 7.24.1 + resolution: "@babel/traverse@npm:7.24.1" + dependencies: + "@babel/code-frame": ^7.24.1 + "@babel/generator": ^7.24.1 + "@babel/helper-environment-visitor": ^7.22.20 + "@babel/helper-function-name": ^7.23.0 + "@babel/helper-hoist-variables": ^7.22.5 + "@babel/helper-split-export-declaration": ^7.22.6 + "@babel/parser": ^7.24.1 + "@babel/types": ^7.24.0 + debug: ^4.3.1 + globals: ^11.1.0 + checksum: 92a5ca906abfba9df17666d2001ab23f18600035f706a687055a0e392a690ae48d6fec67c8bd4ef19ba18699a77a5b7f85727e36b83f7d110141608fe0c24fe9 + languageName: node + linkType: hard + "@babel/types@npm:^7.0.0, @babel/types@npm:^7.20.7, @babel/types@npm:^7.22.15, @babel/types@npm:^7.22.19, @babel/types@npm:^7.22.5, @babel/types@npm:^7.23.0, @babel/types@npm:^7.23.4, @babel/types@npm:^7.23.6, @babel/types@npm:^7.3.3, @babel/types@npm:^7.4.0, @babel/types@npm:^7.4.4, @babel/types@npm:^7.8.3": version: 7.23.6 resolution: "@babel/types@npm:7.23.6" @@ -2238,6 +2359,17 @@ __metadata: languageName: node linkType: hard +"@babel/types@npm:^7.24.0": + version: 7.24.0 + resolution: "@babel/types@npm:7.24.0" + dependencies: + "@babel/helper-string-parser": ^7.23.4 + "@babel/helper-validator-identifier": ^7.22.20 + to-fast-properties: ^2.0.0 + checksum: 4b574a37d490f621470ff36a5afaac6deca5546edcb9b5e316d39acbb20998e9c2be42f3fc0bf2b55906fc49ff2a5a6a097e8f5a726ee3f708a0b0ca93aed807 + languageName: node + linkType: hard + "@bcoe/v8-coverage@npm:^0.2.3": version: 0.2.3 resolution: "@bcoe/v8-coverage@npm:0.2.3" @@ -3442,6 +3574,17 @@ __metadata: languageName: node linkType: hard +"@jridgewell/gen-mapping@npm:^0.3.5": + version: 0.3.5 + resolution: "@jridgewell/gen-mapping@npm:0.3.5" + dependencies: + "@jridgewell/set-array": ^1.2.1 + "@jridgewell/sourcemap-codec": ^1.4.10 + "@jridgewell/trace-mapping": ^0.3.24 + checksum: ff7a1764ebd76a5e129c8890aa3e2f46045109dabde62b0b6c6a250152227647178ff2069ea234753a690d8f3c4ac8b5e7b267bbee272bffb7f3b0a370ab6e52 + languageName: node + linkType: hard + "@jridgewell/resolve-uri@npm:^3.0.3, @jridgewell/resolve-uri@npm:^3.1.0": version: 3.1.1 resolution: "@jridgewell/resolve-uri@npm:3.1.1" @@ -3456,6 +3599,13 @@ __metadata: languageName: node linkType: hard +"@jridgewell/set-array@npm:^1.2.1": + version: 1.2.1 + resolution: "@jridgewell/set-array@npm:1.2.1" + checksum: 832e513a85a588f8ed4f27d1279420d8547743cc37fcad5a5a76fc74bb895b013dfe614d0eed9cb860048e6546b798f8f2652020b4b2ba0561b05caa8c654b10 + languageName: node + linkType: hard + "@jridgewell/source-map@npm:^0.3.3": version: 0.3.5 resolution: "@jridgewell/source-map@npm:0.3.5" @@ -3493,6 +3643,16 @@ __metadata: languageName: node linkType: hard +"@jridgewell/trace-mapping@npm:^0.3.24, @jridgewell/trace-mapping@npm:^0.3.25": + version: 0.3.25 + resolution: "@jridgewell/trace-mapping@npm:0.3.25" + dependencies: + "@jridgewell/resolve-uri": ^3.1.0 + "@jridgewell/sourcemap-codec": ^1.4.14 + checksum: 9d3c40d225e139987b50c48988f8717a54a8c994d8a948ee42e1412e08988761d0754d7d10b803061cc3aebf35f92a5dbbab493bd0e1a9ef9e89a2130e83ba34 + languageName: node + linkType: hard + "@leichtgewicht/ip-codec@npm:^2.0.1": version: 2.0.4 resolution: "@leichtgewicht/ip-codec@npm:2.0.4" @@ -5435,7 +5595,9 @@ __metadata: version: 0.0.0-use.local resolution: "@sitecore-jss/sitecore-jss-dev-tools@workspace:packages/sitecore-jss-dev-tools" dependencies: + "@babel/core": ^7.24.4 "@babel/parser": ^7.24.0 + "@babel/register": ^7.23.7 "@sitecore-jss/sitecore-jss": 21.8.0-canary.6 "@types/chai": ^4.3.4 "@types/chokidar": ^2.1.3 @@ -5453,7 +5615,6 @@ __metadata: "@types/uuid": ^9.0.0 "@types/yargs": ^17.0.22 axios: ^1.3.2 - babel-core: ^6.26.3 chai: ^4.3.7 chalk: ^4.1.2 chokidar: ^3.5.3 @@ -5740,7 +5901,6 @@ __metadata: version: 0.0.0-use.local resolution: "@sitecore-jss/sitecore-jss-vue@workspace:packages/sitecore-jss-vue" dependencies: - "@babel/core": ^7.20.12 "@sitecore-jss/sitecore-jss": 21.8.0-canary.6 "@types/jest": ^29.2.6 "@types/node": ^18.11.18 @@ -5748,7 +5908,6 @@ __metadata: "@vue/compiler-sfc": ^3.0.11 "@vue/test-utils": 2.2.7 "@vue/vue3-jest": ^29.2.2 - babel-core: ^6.26.3 babel-jest: ^29.5.0 del-cli: ^5.0.0 eslint: ^8.32.0 @@ -8692,7 +8851,7 @@ __metadata: languageName: node linkType: hard -"babel-core@npm:6.26.3, babel-core@npm:^6.26.0, babel-core@npm:^6.26.3": +"babel-core@npm:6.26.3, babel-core@npm:^6.26.0": version: 6.26.3 resolution: "babel-core@npm:6.26.3" dependencies: @@ -21485,7 +21644,7 @@ __metadata: languageName: node linkType: hard -"pirates@npm:^4.0.1, pirates@npm:^4.0.4, pirates@npm:^4.0.5": +"pirates@npm:^4.0.1, pirates@npm:^4.0.4, pirates@npm:^4.0.5, pirates@npm:^4.0.6": version: 4.0.6 resolution: "pirates@npm:4.0.6" checksum: 46a65fefaf19c6f57460388a5af9ab81e3d7fd0e7bc44ca59d753cb5c4d0df97c6c6e583674869762101836d68675f027d60f841c105d72734df9dfca97cbcc6