openmrs 4.0.1 → 4.0.2-pre.259
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/.turbo/turbo-build.log +1 -1
- package/README.md +1 -1
- package/dist/commands/develop.js +1 -1
- package/dist/utils/debugger.js +6 -10
- package/package.json +8 -9
- package/src/commands/develop.ts +1 -1
- package/src/utils/debugger.ts +6 -9
package/.turbo/turbo-build.log
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[36mopenmrs:build[0m: cache hit, replaying output [
|
|
1
|
+
[36mopenmrs:build[0m: cache hit, replaying output [2m398c2e0c3f7ffa98[0m
|
package/README.md
CHANGED
package/dist/commands/develop.js
CHANGED
|
@@ -14,7 +14,7 @@ function runDevelop(args) {
|
|
|
14
14
|
const apiUrl = (0, utils_1.removeTrailingSlash)(args.apiUrl);
|
|
15
15
|
const spaPath = (0, utils_1.removeTrailingSlash)(args.spaPath);
|
|
16
16
|
const app = (0, express_1.default)();
|
|
17
|
-
const source = (0, path_1.resolve)(require.resolve("@openmrs/esm-app-shell/package.json"), "..", "
|
|
17
|
+
const source = (0, path_1.resolve)(require.resolve("@openmrs/esm-app-shell/package.json"), "..", "dist");
|
|
18
18
|
const index = (0, path_1.resolve)(source, "index.html");
|
|
19
19
|
const indexContent = (0, fs_1.readFileSync)(index, "utf8")
|
|
20
20
|
.replace(RegExp("<script>[\\s\\S]+</script>"), `
|
package/dist/utils/debugger.js
CHANGED
|
@@ -13,18 +13,14 @@ function loadConfig(configPath) {
|
|
|
13
13
|
return content;
|
|
14
14
|
}
|
|
15
15
|
function debug(configPath, port) {
|
|
16
|
-
const
|
|
16
|
+
const Webpack = require("webpack");
|
|
17
17
|
const WebpackDevServer = require("webpack-dev-server");
|
|
18
18
|
const config = loadConfig(configPath);
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
server
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}
|
|
25
|
-
else {
|
|
26
|
-
(0, logger_1.logInfo)(`Listening at http://localhost:${port}`);
|
|
27
|
-
}
|
|
19
|
+
const compiler = Webpack(config);
|
|
20
|
+
const devServerOptions = Object.assign(Object.assign({}, config.devServer), { port, static: (0, path_1.dirname)(configPath) });
|
|
21
|
+
const server = new WebpackDevServer(devServerOptions, compiler);
|
|
22
|
+
server.startCallback(() => {
|
|
23
|
+
(0, logger_1.logInfo)(`Listening at http://localhost:${port}`);
|
|
28
24
|
});
|
|
29
25
|
}
|
|
30
26
|
process.on("message", ({ source, port }) => debug(source, port));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "openmrs",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.2-pre.259",
|
|
4
4
|
"license": "MPL-2.0",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"bin": "./dist/cli.js",
|
|
@@ -30,15 +30,14 @@
|
|
|
30
30
|
],
|
|
31
31
|
"homepage": "https://github.com/openmrs/openmrs-esm-core#readme",
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@
|
|
34
|
-
"@openmrs/
|
|
35
|
-
"@openmrs/webpack-config": "*",
|
|
33
|
+
"@openmrs/esm-app-shell": "4.0.2-pre.259",
|
|
34
|
+
"@openmrs/webpack-config": "4.0.2-pre.259",
|
|
36
35
|
"autoprefixer": "^10.4.2",
|
|
37
36
|
"axios": "^0.21.1",
|
|
38
37
|
"browserslist-config-openmrs": "^1.0.1",
|
|
39
38
|
"copy-webpack-plugin": "^10.0.0",
|
|
40
39
|
"cssnano": "^5.0.16",
|
|
41
|
-
"ejs": "^
|
|
40
|
+
"ejs": "^3.1.8",
|
|
42
41
|
"glob": "^7.1.3",
|
|
43
42
|
"html-webpack-plugin": "^5.5.0",
|
|
44
43
|
"inquirer": "^7.3.3",
|
|
@@ -49,9 +48,9 @@
|
|
|
49
48
|
"tar": "^6.0.5",
|
|
50
49
|
"ts-loader": "^9.2.6",
|
|
51
50
|
"typescript": "~4.5.2",
|
|
52
|
-
"webpack": "^5.
|
|
53
|
-
"webpack-cli": "^4.
|
|
54
|
-
"webpack-dev-server": "^4.
|
|
51
|
+
"webpack": "^5.74.0",
|
|
52
|
+
"webpack-cli": "^4.10.0",
|
|
53
|
+
"webpack-dev-server": "^4.10.1",
|
|
55
54
|
"webpack-pwa-manifest": "^4.3.0",
|
|
56
55
|
"workbox-webpack-plugin": "^6.4.1",
|
|
57
56
|
"yargs": "16.0.3"
|
|
@@ -66,5 +65,5 @@
|
|
|
66
65
|
"@types/systemjs": "^6.1.0",
|
|
67
66
|
"@types/tar": "^4.0.3"
|
|
68
67
|
},
|
|
69
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "3eea90227e75ec2c366e8c5f1ba9dbd5b070375b"
|
|
70
69
|
}
|
package/src/commands/develop.ts
CHANGED
|
@@ -31,7 +31,7 @@ export function runDevelop(args: DevelopArgs) {
|
|
|
31
31
|
const source = resolve(
|
|
32
32
|
require.resolve("@openmrs/esm-app-shell/package.json"),
|
|
33
33
|
"..",
|
|
34
|
-
"
|
|
34
|
+
"dist"
|
|
35
35
|
);
|
|
36
36
|
const index = resolve(source, "index.html");
|
|
37
37
|
const indexContent = readFileSync(index, "utf8")
|
package/src/utils/debugger.ts
CHANGED
|
@@ -19,24 +19,21 @@ function loadConfig(configPath: string) {
|
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
function debug(configPath: string, port: number) {
|
|
22
|
-
const
|
|
22
|
+
const Webpack = require("webpack");
|
|
23
23
|
const WebpackDevServer = require("webpack-dev-server");
|
|
24
24
|
const config = loadConfig(configPath);
|
|
25
25
|
|
|
26
|
-
const
|
|
26
|
+
const compiler = Webpack(config);
|
|
27
|
+
const devServerOptions = {
|
|
27
28
|
...config.devServer,
|
|
28
29
|
port,
|
|
29
30
|
static: dirname(configPath),
|
|
30
31
|
};
|
|
31
32
|
|
|
32
|
-
const server = new WebpackDevServer(
|
|
33
|
+
const server = new WebpackDevServer(devServerOptions, compiler);
|
|
33
34
|
|
|
34
|
-
server.
|
|
35
|
-
|
|
36
|
-
logWarn(`Error: ${err}`);
|
|
37
|
-
} else {
|
|
38
|
-
logInfo(`Listening at http://localhost:${port}`);
|
|
39
|
-
}
|
|
35
|
+
server.startCallback(() => {
|
|
36
|
+
logInfo(`Listening at http://localhost:${port}`);
|
|
40
37
|
});
|
|
41
38
|
}
|
|
42
39
|
|