@stanlemon/webdev 0.1.48 → 0.1.51
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.
- package/.babelrc.json +0 -1
- package/dist/index.html +1 -1
- package/dist/main.870084e38c47836a0964.js +28 -0
- package/dist/{runtime.517b8971955bd92adc2e.js → runtime.9dafb62f464ccc27efd6.js} +0 -42
- package/dist/{vendors.0a67934fca487f9c9ec7.js → vendors.eae44b81ebb159229b6f.js} +1 -1
- package/jest.config.js +3 -11
- package/package.json +14 -15
- package/webpack.config.js +11 -13
- package/dist/main.7079c69ff92ecf2c5641.js +0 -28
package/.babelrc.json
CHANGED
package/dist/index.html
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="utf-8">
|
|
5
5
|
<title>Webpack App</title>
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1"><script defer src="/runtime.
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1"><script defer src="/runtime.9dafb62f464ccc27efd6.js"></script><script defer src="/react.02ba2699f9d8f6252a54.js"></script><script defer src="/vendors.eae44b81ebb159229b6f.js"></script><script defer src="/main.870084e38c47836a0964.js"></script></head>
|
|
7
7
|
<body>
|
|
8
8
|
</body>
|
|
9
9
|
</html>
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* ATTENTION: An "eval-source-map" devtool has been used.
|
|
4
|
+
* This devtool is neither made for production nor for readable output files.
|
|
5
|
+
* It uses "eval()" calls to create a separate source file with attached SourceMaps in the browser devtools.
|
|
6
|
+
* If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
|
|
7
|
+
* or disable the default devtool with "devtool: false".
|
|
8
|
+
* If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
|
|
9
|
+
*/
|
|
10
|
+
(self["webpackChunk_stanlemon_webdev"] = self["webpackChunk_stanlemon_webdev"] || []).push([["main"],{
|
|
11
|
+
|
|
12
|
+
/***/ 6738:
|
|
13
|
+
/*!**************************!*\
|
|
14
|
+
!*** ./webpack.test.tsx ***!
|
|
15
|
+
\**************************/
|
|
16
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
17
|
+
|
|
18
|
+
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var react_dom_client__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react-dom/client */ 7029);\n/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ 2322);\n/* provided dependency */ var __react_refresh_utils__ = __webpack_require__(/*! ../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js */ 5506);\n__webpack_require__.$Refresh$.runtime = __webpack_require__(/*! ../../node_modules/react-refresh/runtime.js */ 9139);\n\n\n\n\n\nfunction App({\n name\n}) {\n return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(\"div\", {\n children: [\"Hello \", name, \"!\"]\n });\n}\n\n_c = App;\nconst root = (0,react_dom_client__WEBPACK_IMPORTED_MODULE_0__.createRoot)(document.body.appendChild(document.createElement(\"div\")));\nroot.render( /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(App, {\n name: \"world\"\n}));\n\nvar _c;\n\n__webpack_require__.$Refresh$.register(_c, \"App\");\n\nconst $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;\nconst $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(\n\t$ReactRefreshModuleId$\n);\n\nfunction $ReactRefreshModuleRuntime$(exports) {\n\tif (false) {}\n}\n\nif (typeof Promise !== 'undefined' && $ReactRefreshCurrentExports$ instanceof Promise) {\n\t$ReactRefreshCurrentExports$.then($ReactRefreshModuleRuntime$);\n} else {\n\t$ReactRefreshModuleRunt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tZSIsInJvb3QiLCJkb2N1bWVudCIsImJvZHkiLCJhcHBlbmRDaGlsZCIsImNyZWF0ZUVsZW1lbnQiLCJyZW5kZXIiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///6738\n");
|
|
19
|
+
|
|
20
|
+
/***/ })
|
|
21
|
+
|
|
22
|
+
},
|
|
23
|
+
/******/ __webpack_require__ => { // webpackRuntimeModules
|
|
24
|
+
/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
|
|
25
|
+
/******/ __webpack_require__.O(0, ["react-node_modules_react-dom_client_js-node_modules_react-refresh_runtime_js-node_modules_rea-832849","vendors"], () => (__webpack_exec__(794), __webpack_exec__(6101), __webpack_exec__(6738)));
|
|
26
|
+
/******/ var __webpack_exports__ = __webpack_require__.O();
|
|
27
|
+
/******/ }
|
|
28
|
+
]);
|
|
@@ -82,48 +82,6 @@
|
|
|
82
82
|
/******/ };
|
|
83
83
|
/******/ })();
|
|
84
84
|
/******/
|
|
85
|
-
/******/ /* webpack/runtime/create fake namespace object */
|
|
86
|
-
/******/ (() => {
|
|
87
|
-
/******/ var getProto = Object.getPrototypeOf ? (obj) => (Object.getPrototypeOf(obj)) : (obj) => (obj.__proto__);
|
|
88
|
-
/******/ var leafPrototypes;
|
|
89
|
-
/******/ // create a fake namespace object
|
|
90
|
-
/******/ // mode & 1: value is a module id, require it
|
|
91
|
-
/******/ // mode & 2: merge all properties of value into the ns
|
|
92
|
-
/******/ // mode & 4: return value when already ns object
|
|
93
|
-
/******/ // mode & 16: return value when it's Promise-like
|
|
94
|
-
/******/ // mode & 8|1: behave like require
|
|
95
|
-
/******/ __webpack_require__.t = function(value, mode) {
|
|
96
|
-
/******/ if(mode & 1) value = this(value);
|
|
97
|
-
/******/ if(mode & 8) return value;
|
|
98
|
-
/******/ if(typeof value === 'object' && value) {
|
|
99
|
-
/******/ if((mode & 4) && value.__esModule) return value;
|
|
100
|
-
/******/ if((mode & 16) && typeof value.then === 'function') return value;
|
|
101
|
-
/******/ }
|
|
102
|
-
/******/ var ns = Object.create(null);
|
|
103
|
-
/******/ __webpack_require__.r(ns);
|
|
104
|
-
/******/ var def = {};
|
|
105
|
-
/******/ leafPrototypes = leafPrototypes || [null, getProto({}), getProto([]), getProto(getProto)];
|
|
106
|
-
/******/ for(var current = mode & 2 && value; typeof current == 'object' && !~leafPrototypes.indexOf(current); current = getProto(current)) {
|
|
107
|
-
/******/ Object.getOwnPropertyNames(current).forEach((key) => (def[key] = () => (value[key])));
|
|
108
|
-
/******/ }
|
|
109
|
-
/******/ def['default'] = () => (value);
|
|
110
|
-
/******/ __webpack_require__.d(ns, def);
|
|
111
|
-
/******/ return ns;
|
|
112
|
-
/******/ };
|
|
113
|
-
/******/ })();
|
|
114
|
-
/******/
|
|
115
|
-
/******/ /* webpack/runtime/define property getters */
|
|
116
|
-
/******/ (() => {
|
|
117
|
-
/******/ // define getter functions for harmony exports
|
|
118
|
-
/******/ __webpack_require__.d = (exports, definition) => {
|
|
119
|
-
/******/ for(var key in definition) {
|
|
120
|
-
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
|
121
|
-
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
|
122
|
-
/******/ }
|
|
123
|
-
/******/ }
|
|
124
|
-
/******/ };
|
|
125
|
-
/******/ })();
|
|
126
|
-
/******/
|
|
127
85
|
/******/ /* webpack/runtime/global */
|
|
128
86
|
/******/ (() => {
|
|
129
87
|
/******/ __webpack_require__.g = (function() {
|
|
@@ -1455,7 +1455,7 @@ eval("/* global __webpack_dev_server_client__ */\n\nconst getSocketUrlParts = __
|
|
|
1455
1455
|
\*******************************************************************************************************/
|
|
1456
1456
|
/***/ ((module) => {
|
|
1457
1457
|
|
|
1458
|
-
eval("/**\n * Gets the source (i.e. host) of the script currently running.\n * @returns {string}\n */\nfunction getCurrentScriptSource() {\n // `document.currentScript` is the most accurate way to get the current running script,\n // but is not supported in all browsers (most notably, IE).\n if (document
|
|
1458
|
+
eval("/**\n * Gets the source (i.e. host) of the script currently running.\n * @returns {string}\n */\nfunction getCurrentScriptSource() {\n // `document.currentScript` is the most accurate way to get the current running script,\n // but is not supported in all browsers (most notably, IE).\n if ('currentScript' in document) {\n // In some cases, `document.currentScript` would be `null` even if the browser supports it:\n // e.g. asynchronous chunks on Firefox.\n // We should not fallback to the list-approach as it would not be safe.\n if (document.currentScript == null) return;\n return document.currentScript.getAttribute('src');\n }\n // Fallback to getting all scripts running in the document,\n // and finding the last one injected.\n else {\n const scriptElementsWithSrc = Array.prototype.filter.call(\n document.scripts || [],\n function (elem) {\n return elem.getAttribute('src');\n }\n );\n if (!scriptElementsWithSrc.length) return;\n const currentScript = scriptElementsWithSrc[scriptElementsWithSrc.length - 1];\n return currentScript.getAttribute('src');\n }\n}\n\nmodule.exports = getCurrentScriptSource;\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNzYyOS5qcyIsIm1hcHBpbmdzIjoiQUFBQTtBQUNBO0FBQ0EsYUFBYTtBQUNiO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vQHN0YW5sZW1vbi93ZWJkZXYvLi4vLi4vbm9kZV9tb2R1bGVzL0BwbW1td2gvcmVhY3QtcmVmcmVzaC13ZWJwYWNrLXBsdWdpbi9zb2NrZXRzL3V0aWxzL2dldEN1cnJlbnRTY3JpcHRTb3VyY2UuanM/NDMzMiJdLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdldHMgdGhlIHNvdXJjZSAoaS5lLiBob3N0KSBvZiB0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nNjcmlwdHMgfHwgW10sXG4gICAgICBmdW5jdGlvbiAoZWxlbSkge1xuICAgICAgICByZXR1cm4gZWxlbS5nZXRBdHRyaWJ1dGUoJ3NyYycpO1xuICAgICAgfVxuICAgICk7XG4gICAgaWYgKCFzY3JpcHRFbGVtZW50c1dpdGhTcmMubGVuZ3RoKSByZXR1cm47XG4gICAgY29uc3QgY3VycmVudFNjcmlwdCA9IHNjcmlwdEVsZW1lbnRzV2l0aFNyY1tzY3JpcHRFbGVtZW50c1dpdGhTcmMubGVuZ3RoIC0gMV07XG4gICAgcmV0dXJuIGN1cnJlbnRTY3JpcHQuZ2V0QXR0cmlidXRlKCdzcmMnKTtcbiAgfVxufVxuXG5tb2R1bGUuZXhwb3J0cyA9IGdldEN1cnJlbnRTY3JpcHRTb3VyY2U7XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///7629\n");
|
|
1459
1459
|
|
|
1460
1460
|
/***/ }),
|
|
1461
1461
|
|
package/jest.config.js
CHANGED
|
@@ -1,18 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
import { fileURLToPath } from "url";
|
|
3
|
-
import { readFileSync } from "fs";
|
|
1
|
+
const path = require("path");
|
|
4
2
|
|
|
5
|
-
const babelOptions =
|
|
6
|
-
readFileSync(new URL("./.babelrc.json", import.meta.url))
|
|
7
|
-
);
|
|
3
|
+
const babelOptions = require("./.babelrc.json");
|
|
8
4
|
|
|
9
5
|
// Disable using esmodules everywhere
|
|
10
6
|
babelOptions.presets.find(
|
|
11
7
|
(preset) => preset[0] === "@babel/preset-env"
|
|
12
8
|
)[1].modules = "auto";
|
|
13
9
|
|
|
14
|
-
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
15
|
-
|
|
16
10
|
// These are packages we know ship with esmodules and need to be transformed
|
|
17
11
|
const esModules = [
|
|
18
12
|
"uuid",
|
|
@@ -21,11 +15,9 @@ const esModules = [
|
|
|
21
15
|
"lodash-es",
|
|
22
16
|
"@stanlemon/server",
|
|
23
17
|
"@stanlemon/server-with-auth",
|
|
24
|
-
"@stanlemon/react-pouchdb",
|
|
25
|
-
"@stanlemon/react-couchdb-authentication",
|
|
26
18
|
].join("|");
|
|
27
19
|
|
|
28
|
-
|
|
20
|
+
module.exports = {
|
|
29
21
|
verbose: true,
|
|
30
22
|
setupFilesAfterEnv: [path.resolve(__dirname, "./jest.setup.js")],
|
|
31
23
|
testEnvironment: "jsdom",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stanlemon/webdev",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.51",
|
|
4
4
|
"description": "My typical web development setup, but without all the copy and paste.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"webpack",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"engines": {
|
|
14
14
|
"node": ">=16.13.0"
|
|
15
15
|
},
|
|
16
|
-
"type": "
|
|
16
|
+
"type": "commonjs",
|
|
17
17
|
"scripts": {
|
|
18
18
|
"test": "WEBDEV_ENTRY=./webpack.test.tsx webpack build",
|
|
19
19
|
"lint": "eslint --ext js,jsx,ts,tsx ./",
|
|
@@ -21,25 +21,24 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@babel/cli": "^7.17.10",
|
|
24
|
-
"@babel/core": "^7.
|
|
25
|
-
"@babel/preset-env": "^7.
|
|
26
|
-
"@babel/preset-react": "^7.
|
|
27
|
-
"@babel/preset-typescript": "^7.
|
|
28
|
-
"@peculiar/webcrypto": "^1.
|
|
29
|
-
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.
|
|
24
|
+
"@babel/core": "^7.18.0",
|
|
25
|
+
"@babel/preset-env": "^7.18.0",
|
|
26
|
+
"@babel/preset-react": "^7.17.12",
|
|
27
|
+
"@babel/preset-typescript": "^7.17.12",
|
|
28
|
+
"@peculiar/webcrypto": "^1.4.0",
|
|
29
|
+
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.6",
|
|
30
30
|
"@stanlemon/eslint-config": "*",
|
|
31
31
|
"@testing-library/jest-dom": "^5.16.4",
|
|
32
|
-
"@types/jest": "^27.5.
|
|
32
|
+
"@types/jest": "^27.5.1",
|
|
33
33
|
"@types/react": "^18.0.9",
|
|
34
|
-
"@types/react-dom": "^18.0.
|
|
34
|
+
"@types/react-dom": "^18.0.4",
|
|
35
35
|
"@types/webpack": "^5.28.0",
|
|
36
|
-
"@types/webpack-env": "^1.
|
|
36
|
+
"@types/webpack-env": "^1.17.0",
|
|
37
37
|
"babel-jest": "^28.1.0",
|
|
38
38
|
"babel-loader": "^8.2.5",
|
|
39
|
-
"babel-plugin-add-import-extension": "^1.6.0",
|
|
40
39
|
"clean-webpack-plugin": "^4.0.0",
|
|
41
40
|
"css-loader": "^6.7.1",
|
|
42
|
-
"dotenv": "^16.0.
|
|
41
|
+
"dotenv": "^16.0.1",
|
|
43
42
|
"html-webpack-plugin": "^5.5.0",
|
|
44
43
|
"identity-obj-proxy": "^3.0.0",
|
|
45
44
|
"jest": "^28.1.0",
|
|
@@ -50,13 +49,13 @@
|
|
|
50
49
|
"react-refresh": "^0.13.0",
|
|
51
50
|
"style-loader": "^3.3.1",
|
|
52
51
|
"typescript": "^4.6.4",
|
|
53
|
-
"webpack": "^5.72.
|
|
52
|
+
"webpack": "^5.72.1",
|
|
54
53
|
"webpack-bundle-analyzer": "^4.5.0",
|
|
55
54
|
"webpack-cli": "^4.9.2",
|
|
56
55
|
"webpack-dev-server": "^4.9.0"
|
|
57
56
|
},
|
|
58
57
|
"devDependencies": {
|
|
59
|
-
"@types/react-dom": "^18.0.
|
|
58
|
+
"@types/react-dom": "^18.0.4",
|
|
60
59
|
"react": "^18.1.0",
|
|
61
60
|
"react-dom": "^18.1.0"
|
|
62
61
|
},
|
package/webpack.config.js
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
const path = require("path");
|
|
2
|
+
const { existsSync } = require("fs");
|
|
3
|
+
const webpack = require("webpack");
|
|
4
|
+
const HtmlWebpackPlugin = require("html-webpack-plugin");
|
|
5
|
+
const ReactRefreshWebpackPlugin = require("@pmmmwh/react-refresh-webpack-plugin");
|
|
6
|
+
const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer");
|
|
7
|
+
const { CleanWebpackPlugin } = require("clean-webpack-plugin");
|
|
8
|
+
const { config } = require("dotenv");
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
config();
|
|
11
11
|
|
|
12
|
-
const babelOptions =
|
|
13
|
-
readFileSync(new URL("./.babelrc.json", import.meta.url))
|
|
14
|
-
);
|
|
12
|
+
const babelOptions = require("./.babelrc.json");
|
|
15
13
|
|
|
16
14
|
// Entry points, which can be separated by a semi-colon
|
|
17
15
|
const WEBDEV_ENTRY = process.env.WEBDEV_ENTRY ?? "./src/index.tsx";
|
|
@@ -37,7 +35,7 @@ WEBDEV_PROXY.split(";").forEach((entry) => {
|
|
|
37
35
|
|
|
38
36
|
const isDevelopment = NODE_ENV !== "production";
|
|
39
37
|
|
|
40
|
-
|
|
38
|
+
module.exports = {
|
|
41
39
|
mode: isDevelopment ? "development" : "production",
|
|
42
40
|
entry: WEBDEV_ENTRY.split(";"),
|
|
43
41
|
output: {
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* ATTENTION: An "eval-source-map" devtool has been used.
|
|
4
|
-
* This devtool is neither made for production nor for readable output files.
|
|
5
|
-
* It uses "eval()" calls to create a separate source file with attached SourceMaps in the browser devtools.
|
|
6
|
-
* If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
|
|
7
|
-
* or disable the default devtool with "devtool: false".
|
|
8
|
-
* If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
|
|
9
|
-
*/
|
|
10
|
-
(self["webpackChunk_stanlemon_webdev"] = self["webpackChunk_stanlemon_webdev"] || []).push([["main"],{
|
|
11
|
-
|
|
12
|
-
/***/ 6738:
|
|
13
|
-
/*!**************************!*\
|
|
14
|
-
!*** ./webpack.test.tsx ***!
|
|
15
|
-
\**************************/
|
|
16
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
17
|
-
|
|
18
|
-
eval("var _home_runner_work_javascript_javascript_node_modules_react_refresh_runtime_js__WEBPACK_IMPORTED_MODULE_0___namespace_cache;\n__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _home_runner_work_javascript_javascript_node_modules_react_refresh_runtime_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../node_modules/react-refresh/runtime.js */ 9139);\n/* harmony import */ var react_dom_client__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react-dom/client */ 7029);\n/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react/jsx-runtime */ 2322);\n/* provided dependency */ var __react_refresh_utils__ = __webpack_require__(/*! ../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js */ 5506);\n\n__webpack_require__.$Refresh$.runtime = /*#__PURE__*/ (_home_runner_work_javascript_javascript_node_modules_react_refresh_runtime_js__WEBPACK_IMPORTED_MODULE_0___namespace_cache || (_home_runner_work_javascript_javascript_node_modules_react_refresh_runtime_js__WEBPACK_IMPORTED_MODULE_0___namespace_cache = __webpack_require__.t(_home_runner_work_javascript_javascript_node_modules_react_refresh_runtime_js__WEBPACK_IMPORTED_MODULE_0__, 2)));\n\n\n\n\n\nfunction App({\n name\n}) {\n return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsxs)(\"div\", {\n children: [\"Hello \", name, \"!\"]\n });\n}\n\n_c = App;\nconst root = (0,react_dom_client__WEBPACK_IMPORTED_MODULE_1__.createRoot)(document.body.appendChild(document.createElement(\"div\")));\nroot.render( /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(App, {\n name: \"world\"\n}));\n\nvar _c;\n\n__webpack_require__.$Refresh$.register(_c, \"App\");\n\nconst $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;\nconst $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(\n\t$ReactRefreshModuleId$\n);\n\nfunction $ReactRefreshModuleRuntime$(exports) {\n\tif (false) {}\n}\n\nif (typeof Promise !== 'undefined' && $ReactRefreshCurrentExports$ instanceof Promise) {\n\t$ReactRefreshCurrentExports$.then($ReactRefreshModuleRuntime$);\n} else {\n\t$ReactRefreshModuleRuntime$($ReactRefreshCurrentExports$);\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNjczOC5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7QUFBQTs7OztBQU1BLFNBQVNDLEdBQVQsQ0FBYTtFQUFFQztBQUFGLENBQWIsRUFBOEI7RUFDNUIsb0JBQU87SUFBQSxxQkFBWUEsSUFBWjtFQUFBLEVBQVA7QUFDRDs7S0FGUUQ7QUFJVCxNQUFNRSxJQUFJLEdBQUdILDREQUFVLENBQ3JCSSxRQUFRLENBQUNDLElBQVQsQ0FBY0MsV0FBZCxDQUEwQkYsUUFBUSxDQUFDRyxhQUFULENBQXVCLEtBQXZCLENBQTFCLENBRHFCLENBQXZCO0FBR0FKLElBQUksQ0FBQ0ssTUFBTCxlQUFZLHVEQUFDLEdBQUQ7RUFBSyxJQUFJLEVBQUM7QUFBVixFQUFaIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vQHN0YW5sZW1vbi93ZWJkZXYvLi93ZWJwYWNrLnRlc3QudHN4PzgzYmMiXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgY3JlYXRlUm9vdCB9IGZyb20gXCJyZWFjdC1kb20vY2xpZW50XCI7XG5cbnR5cGUgUHJvcHMgPSB7XG4gIG5hbWU6IHN0cmluZztcbn07XG5cbmZ1bmN0aW9uIEFwcCh7IG5hbWUgfTogUHJvcHMpIHtcbiAgcmV0dXJuIDxkaXY+SGVsbG8ge25hbWV9ITwvZGl2Pjtcbn1cblxuY29uc3Qgcm9vdCA9IGNyZWF0ZVJvb3QoXG4gIGRvY3VtZW50LmJvZHkuYXBwZW5kQ2hpbGQoZG9jdW1lbnQuY3JlYXRlRWxlbWVudChcImRpdlwiKSlcbik7XG5yb290LnJlbmRlcig8QXBwIG5hbWU9XCJ3b3JsZFwiIC8+KTtcbiJdLCJuYW1lcyI6WyJjcmVhdGVSb290IiwiQXBwIiwibmFtZSIsInJvb3QiLCJkb2N1bWVudCIsImJvZHkiLCJhcHBlbmRDaGlsZCIsImNyZWF0ZUVsZW1lbnQiLCJyZW5kZXIiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///6738\n");
|
|
19
|
-
|
|
20
|
-
/***/ })
|
|
21
|
-
|
|
22
|
-
},
|
|
23
|
-
/******/ __webpack_require__ => { // webpackRuntimeModules
|
|
24
|
-
/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
|
|
25
|
-
/******/ __webpack_require__.O(0, ["react-node_modules_react-dom_client_js-node_modules_react-refresh_runtime_js-node_modules_rea-832849","vendors"], () => (__webpack_exec__(794), __webpack_exec__(6101), __webpack_exec__(6738)));
|
|
26
|
-
/******/ var __webpack_exports__ = __webpack_require__.O();
|
|
27
|
-
/******/ }
|
|
28
|
-
]);
|