@unsetsoft/ryunixjs 0.3.2-nightly.8 → 0.3.2
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/package.json +1 -1
- package/utils/config.cjs +1 -4
- package/webpack.config.mjs +7 -5
package/package.json
CHANGED
package/utils/config.cjs
CHANGED
|
@@ -4,11 +4,8 @@ const configFile = path.join(__dirname, "../../../../", "ryunix.config.js");
|
|
|
4
4
|
|
|
5
5
|
let config = {};
|
|
6
6
|
|
|
7
|
-
console.log(configFile);
|
|
8
|
-
|
|
9
7
|
if (fs.existsSync(configFile)) {
|
|
10
|
-
config = require(
|
|
11
|
-
console.log(config);
|
|
8
|
+
config = require("../../../../ryunix.config.js");
|
|
12
9
|
console.log("[info] configuration file was found.");
|
|
13
10
|
}
|
|
14
11
|
|
package/webpack.config.mjs
CHANGED
|
@@ -22,13 +22,15 @@ if (manager === "yarn" || manager === "npm" || manager === "bun") {
|
|
|
22
22
|
throw new Error(`The manager ${manager} is not supported.`);
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
+
const mode = config.production ? "production" : "development";
|
|
26
|
+
|
|
25
27
|
export default {
|
|
26
|
-
mode
|
|
27
|
-
context:
|
|
28
|
+
mode,
|
|
29
|
+
context: join(dir, config.appDirectory),
|
|
28
30
|
entry: "./main.ryx",
|
|
29
31
|
devtool: "nosources-source-map",
|
|
30
32
|
output: {
|
|
31
|
-
path:
|
|
33
|
+
path: join(dir, config.buildDirectory),
|
|
32
34
|
chunkFilename: "./assets/js/[name].[fullhash:8].bundle.js",
|
|
33
35
|
assetModuleFilename: "./assets/media/[name].[hash][ext]",
|
|
34
36
|
filename: "./assets/js/[name].[fullhash:8].bundle.js",
|
|
@@ -129,8 +131,8 @@ export default {
|
|
|
129
131
|
},
|
|
130
132
|
plugins: [
|
|
131
133
|
new HtmlWebpackPlugin({
|
|
132
|
-
favicon:
|
|
133
|
-
template:
|
|
134
|
+
favicon: join(dir, `${config.publicDirectory}/favicon.png`),
|
|
135
|
+
template: join(dir, `${config.publicDirectory}/index.html`),
|
|
134
136
|
}),
|
|
135
137
|
],
|
|
136
138
|
externals: {
|