@akanjs/config 0.0.127 → 0.0.129

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.
@@ -45,14 +45,14 @@ const getLocalIP = () => {
45
45
  return "127.0.0.1";
46
46
  };
47
47
  const withBase = (applyConfig) => {
48
- const projectName = process.env.NEXT_PUBLIC_APP_NAME;
49
- if (!projectName)
50
- throw new Error("projectName is not defined, please run with nx command");
48
+ const appName = process.env.NEXT_PUBLIC_APP_NAME ?? "seon";
49
+ if (!appName)
50
+ throw new Error("appName is not defined, please run with akan command");
51
51
  const ip = getLocalIP();
52
52
  const baseConfig = {
53
- appId: `com.${projectName}`,
54
- appName: projectName,
55
- webDir: `../../dist/apps/${projectName}/csr/`,
53
+ appId: `com.${appName}.test`,
54
+ appName,
55
+ webDir: `../../dist/apps/${appName}/csr`,
56
56
  // bundledWebRuntime: false, !not used
57
57
  server: process.env.APP_OPERATION_MODE !== "release" ? {
58
58
  androidScheme: "http",
@@ -90,6 +90,12 @@ CMD ["npm", "start"]`,
90
90
  config.frontend?.routes
91
91
  ),
92
92
  explicitDependencies: config.frontend?.explicitDependencies ?? []
93
+ },
94
+ mobile: {
95
+ appName: config.mobile?.appName ?? name,
96
+ bundleId: config.mobile?.bundleId ?? `com.${repoName}.${name}`,
97
+ version: config.mobile?.version,
98
+ buildNum: config.mobile?.buildNum
93
99
  }
94
100
  };
95
101
  };
@@ -13,14 +13,14 @@ const getLocalIP = () => {
13
13
  return "127.0.0.1";
14
14
  };
15
15
  const withBase = (applyConfig) => {
16
- const projectName = process.env.NEXT_PUBLIC_APP_NAME;
17
- if (!projectName)
18
- throw new Error("projectName is not defined, please run with nx command");
16
+ const appName = process.env.NEXT_PUBLIC_APP_NAME ?? "seon";
17
+ if (!appName)
18
+ throw new Error("appName is not defined, please run with akan command");
19
19
  const ip = getLocalIP();
20
20
  const baseConfig = {
21
- appId: `com.${projectName}`,
22
- appName: projectName,
23
- webDir: `../../dist/apps/${projectName}/csr/`,
21
+ appId: `com.${appName}.test`,
22
+ appName,
23
+ webDir: `../../dist/apps/${appName}/csr`,
24
24
  // bundledWebRuntime: false, !not used
25
25
  server: process.env.APP_OPERATION_MODE !== "release" ? {
26
26
  androidScheme: "http",
@@ -54,6 +54,12 @@ CMD ["npm", "start"]`,
54
54
  config.frontend?.routes
55
55
  ),
56
56
  explicitDependencies: config.frontend?.explicitDependencies ?? []
57
+ },
58
+ mobile: {
59
+ appName: config.mobile?.appName ?? name,
60
+ bundleId: config.mobile?.bundleId ?? `com.${repoName}.${name}`,
61
+ version: config.mobile?.version,
62
+ buildNum: config.mobile?.buildNum
57
63
  }
58
64
  };
59
65
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akanjs/config",
3
- "version": "0.0.127",
3
+ "version": "0.0.129",
4
4
  "sourceType": "module",
5
5
  "module": {
6
6
  "access": "public"
package/src/types.d.ts CHANGED
@@ -31,6 +31,12 @@ export interface AppConfigResult {
31
31
  }[];
32
32
  explicitDependencies: ExplicitDependencies;
33
33
  };
34
+ mobile: {
35
+ appName: string;
36
+ bundleId: string;
37
+ version?: string;
38
+ buildNum?: number;
39
+ };
34
40
  }
35
41
  export interface LibConfigResult {
36
42
  rootLib?: string;