@modern-js/runtime 2.69.0 → 2.69.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -171,7 +171,7 @@ const documentPlugin = () => ({
171
171
  if (html.includes(import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_START) && html.includes(import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_END)) {
172
172
  const { nonce } = config.security || {};
173
173
  const nonceAttr = nonce ? `nonce=${nonce}` : "";
174
- html = html.replace(new RegExp(`${import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_START}${import_constants.DOCUMENT_SCRIPT_ATTRIBUTES_START}(.*)${import_constants.DOCUMENT_SCRIPT_ATTRIBUTES_END}(.*?)${import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_END}`, "g"), (_scriptStr, $1, $2) => `<script ${decodeURIComponent($1)} ${nonceAttr}>${decodeURIComponent($2)}</script>`);
174
+ html = html.replace(new RegExp(`${import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_START}${import_constants.DOCUMENT_SCRIPT_ATTRIBUTES_START}(.*?)${import_constants.DOCUMENT_SCRIPT_ATTRIBUTES_END}(.*?)${import_constants.DOCUMENT_SCRIPT_PLACEHOLDER_END}`, "g"), (_scriptStr, $1, $2) => `<script ${decodeURIComponent($1)} ${nonceAttr}>${decodeURIComponent($2)}</script>`);
175
175
  }
176
176
  if (html.includes(import_constants.DOCUMENT_STYLE_PLACEHOLDER_START) && html.includes(import_constants.DOCUMENT_STYLE_PLACEHOLDER_END)) {
177
177
  html = html.replace(new RegExp(`${import_constants.DOCUMENT_STYLE_PLACEHOLDER_START}(.*?)${import_constants.DOCUMENT_STYLE_PLACEHOLDER_END}`, "g"), (_styleStr, $1) => `<style>${decodeURIComponent($1)}</style>`);
@@ -197,7 +197,7 @@ var documentPlugin = function() {
197
197
  if (html.includes(DOCUMENT_SCRIPT_PLACEHOLDER_START) && html.includes(DOCUMENT_SCRIPT_PLACEHOLDER_END)) {
198
198
  nonce = (config.security || {}).nonce;
199
199
  nonceAttr = nonce ? "nonce=".concat(nonce) : "";
200
- html = html.replace(new RegExp("".concat(DOCUMENT_SCRIPT_PLACEHOLDER_START).concat(DOCUMENT_SCRIPT_ATTRIBUTES_START, "(.*)").concat(DOCUMENT_SCRIPT_ATTRIBUTES_END, "(.*?)").concat(DOCUMENT_SCRIPT_PLACEHOLDER_END), "g"), function(_scriptStr, $1, $2) {
200
+ html = html.replace(new RegExp("".concat(DOCUMENT_SCRIPT_PLACEHOLDER_START).concat(DOCUMENT_SCRIPT_ATTRIBUTES_START, "(.*?)").concat(DOCUMENT_SCRIPT_ATTRIBUTES_END, "(.*?)").concat(DOCUMENT_SCRIPT_PLACEHOLDER_END), "g"), function(_scriptStr, $1, $2) {
201
201
  return "<script ".concat(decodeURIComponent($1), " ").concat(nonceAttr, ">").concat(decodeURIComponent($2), "</script>");
202
202
  });
203
203
  }
@@ -136,7 +136,7 @@ const documentPlugin = () => ({
136
136
  if (html.includes(DOCUMENT_SCRIPT_PLACEHOLDER_START) && html.includes(DOCUMENT_SCRIPT_PLACEHOLDER_END)) {
137
137
  const { nonce } = config.security || {};
138
138
  const nonceAttr = nonce ? `nonce=${nonce}` : "";
139
- html = html.replace(new RegExp(`${DOCUMENT_SCRIPT_PLACEHOLDER_START}${DOCUMENT_SCRIPT_ATTRIBUTES_START}(.*)${DOCUMENT_SCRIPT_ATTRIBUTES_END}(.*?)${DOCUMENT_SCRIPT_PLACEHOLDER_END}`, "g"), (_scriptStr, $1, $2) => `<script ${decodeURIComponent($1)} ${nonceAttr}>${decodeURIComponent($2)}</script>`);
139
+ html = html.replace(new RegExp(`${DOCUMENT_SCRIPT_PLACEHOLDER_START}${DOCUMENT_SCRIPT_ATTRIBUTES_START}(.*?)${DOCUMENT_SCRIPT_ATTRIBUTES_END}(.*?)${DOCUMENT_SCRIPT_PLACEHOLDER_END}`, "g"), (_scriptStr, $1, $2) => `<script ${decodeURIComponent($1)} ${nonceAttr}>${decodeURIComponent($2)}</script>`);
140
140
  }
141
141
  if (html.includes(DOCUMENT_STYLE_PLACEHOLDER_START) && html.includes(DOCUMENT_STYLE_PLACEHOLDER_END)) {
142
142
  html = html.replace(new RegExp(`${DOCUMENT_STYLE_PLACEHOLDER_START}(.*?)${DOCUMENT_STYLE_PLACEHOLDER_END}`, "g"), (_styleStr, $1) => `<style>${decodeURIComponent($1)}</style>`);
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "modern",
16
16
  "modern.js"
17
17
  ],
18
- "version": "2.69.0",
18
+ "version": "2.69.1",
19
19
  "engines": {
20
20
  "node": ">=14.17.6"
21
21
  },
@@ -219,13 +219,13 @@
219
219
  "react-is": "^18",
220
220
  "react-side-effect": "^2.1.2",
221
221
  "styled-components": "^5.3.1",
222
- "@modern-js/plugin": "2.69.0",
223
- "@modern-js/plugin-data-loader": "2.69.0",
224
- "@modern-js/plugin-v2": "2.69.0",
225
- "@modern-js/render": "2.69.0",
226
- "@modern-js/types": "2.69.0",
227
- "@modern-js/runtime-utils": "2.69.0",
228
- "@modern-js/utils": "2.69.0"
222
+ "@modern-js/plugin": "2.69.1",
223
+ "@modern-js/plugin-data-loader": "2.69.1",
224
+ "@modern-js/plugin-v2": "2.69.1",
225
+ "@modern-js/render": "2.69.1",
226
+ "@modern-js/runtime-utils": "2.69.1",
227
+ "@modern-js/types": "2.69.1",
228
+ "@modern-js/utils": "2.69.1"
229
229
  },
230
230
  "peerDependencies": {
231
231
  "react": ">=17",
@@ -249,10 +249,10 @@
249
249
  "ts-node": "^10.9.1",
250
250
  "typescript": "^5",
251
251
  "webpack": "^5.102.1",
252
+ "@modern-js/app-tools": "2.69.1",
252
253
  "@scripts/build": "2.66.0",
253
- "@modern-js/app-tools": "2.69.0",
254
254
  "@scripts/jest-config": "2.66.0",
255
- "@modern-js/core": "2.69.0"
255
+ "@modern-js/core": "2.69.1"
256
256
  },
257
257
  "sideEffects": false,
258
258
  "publishConfig": {