@akanjs/config 0.9.40 → 0.9.42

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.
@@ -43,7 +43,7 @@ var import_types = require("./types");
43
43
  const import_meta = {};
44
44
  const jiti = (0, import_jiti.createJiti)(import_meta.url);
45
45
  const makeAppConfig = (config, props) => {
46
- const { name, repoName, serveDomain, env, command = "build" } = props;
46
+ const { name, repoName } = props;
47
47
  return {
48
48
  rootLib: config.rootLib,
49
49
  libs: config.libs ?? [],
@@ -105,8 +105,7 @@ const getNextConfig = (configImp, appData) => {
105
105
  name: appInfo.name,
106
106
  repoName: appInfo.repoName,
107
107
  serveDomain: appInfo.serveDomain,
108
- env: process.env.NEXT_PUBLIC_ENV ?? "debug",
109
- command: "build"
108
+ env: process.env.NEXT_PUBLIC_ENV ?? "debug"
110
109
  };
111
110
  const config = typeof configImp === "function" ? configImp(props) : configImp;
112
111
  const akanConfig = makeAppConfig(config, props);
package/cjs/src/types.js CHANGED
@@ -17,43 +17,7 @@ var __copyProps = (to, from, except, desc) => {
17
17
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
18
  var types_exports = {};
19
19
  __export(types_exports, {
20
- archs: () => archs,
21
- getDefaultFileScan: () => getDefaultFileScan
20
+ archs: () => archs
22
21
  });
23
22
  module.exports = __toCommonJS(types_exports);
24
23
  const archs = ["amd64", "arm64"];
25
- const getDefaultFileScan = () => ({
26
- constants: {
27
- databases: [],
28
- scalars: []
29
- },
30
- dictionary: {
31
- databases: [],
32
- services: [],
33
- scalars: []
34
- },
35
- documents: {
36
- databases: [],
37
- scalars: []
38
- },
39
- services: {
40
- databases: [],
41
- services: [],
42
- scalars: []
43
- },
44
- signal: {
45
- databases: [],
46
- services: [],
47
- scalars: []
48
- },
49
- store: {
50
- databases: [],
51
- services: [],
52
- scalars: []
53
- },
54
- components: {
55
- databases: [],
56
- services: [],
57
- scalars: []
58
- }
59
- });
@@ -7,7 +7,7 @@ import {
7
7
  } from "./types";
8
8
  const jiti = createJiti(import.meta.url);
9
9
  const makeAppConfig = (config, props) => {
10
- const { name, repoName, serveDomain, env, command = "build" } = props;
10
+ const { name, repoName } = props;
11
11
  return {
12
12
  rootLib: config.rootLib,
13
13
  libs: config.libs ?? [],
@@ -69,8 +69,7 @@ const getNextConfig = (configImp, appData) => {
69
69
  name: appInfo.name,
70
70
  repoName: appInfo.repoName,
71
71
  serveDomain: appInfo.serveDomain,
72
- env: process.env.NEXT_PUBLIC_ENV ?? "debug",
73
- command: "build"
72
+ env: process.env.NEXT_PUBLIC_ENV ?? "debug"
74
73
  };
75
74
  const config = typeof configImp === "function" ? configImp(props) : configImp;
76
75
  const akanConfig = makeAppConfig(config, props);
package/esm/src/types.js CHANGED
@@ -1,40 +1,4 @@
1
1
  const archs = ["amd64", "arm64"];
2
- const getDefaultFileScan = () => ({
3
- constants: {
4
- databases: [],
5
- scalars: []
6
- },
7
- dictionary: {
8
- databases: [],
9
- services: [],
10
- scalars: []
11
- },
12
- documents: {
13
- databases: [],
14
- scalars: []
15
- },
16
- services: {
17
- databases: [],
18
- services: [],
19
- scalars: []
20
- },
21
- signal: {
22
- databases: [],
23
- services: [],
24
- scalars: []
25
- },
26
- store: {
27
- databases: [],
28
- services: [],
29
- scalars: []
30
- },
31
- components: {
32
- databases: [],
33
- services: [],
34
- scalars: []
35
- }
36
- });
37
2
  export {
38
- archs,
39
- getDefaultFileScan
3
+ archs
40
4
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akanjs/config",
3
- "version": "0.9.40",
3
+ "version": "0.9.42",
4
4
  "sourceType": "module",
5
5
  "module": {
6
6
  "access": "public"
package/src/types.d.ts CHANGED
@@ -5,7 +5,6 @@ export interface RunnerProps {
5
5
  repoName: string;
6
6
  serveDomain: string;
7
7
  env: "testing" | "local" | "debug" | "develop" | "main";
8
- command?: string;
9
8
  }
10
9
  export declare const archs: readonly ["amd64", "arm64"];
11
10
  export type Arch = (typeof archs)[number];
@@ -71,7 +70,7 @@ export interface AkanConfigFile {
71
70
  default: NextConfig;
72
71
  }
73
72
  export interface FileConventionScanResult {
74
- constants: {
73
+ constant: {
75
74
  databases: string[];
76
75
  scalars: string[];
77
76
  };
@@ -80,59 +79,63 @@ export interface FileConventionScanResult {
80
79
  services: string[];
81
80
  scalars: string[];
82
81
  };
83
- documents: {
82
+ document: {
84
83
  databases: string[];
85
84
  scalars: string[];
86
85
  };
87
- services: {
86
+ service: {
88
87
  databases: string[];
89
88
  services: string[];
90
- scalars: string[];
91
89
  };
92
90
  signal: {
93
91
  databases: string[];
94
92
  services: string[];
95
- scalars: string[];
96
93
  };
97
94
  store: {
98
95
  databases: string[];
99
96
  services: string[];
97
+ };
98
+ template: {
99
+ databases: string[];
100
+ services: string[];
101
+ scalars: string[];
102
+ };
103
+ unit: {
104
+ databases: string[];
105
+ services: string[];
106
+ scalars: string[];
107
+ };
108
+ util: {
109
+ databases: string[];
110
+ services: string[];
111
+ scalars: string[];
112
+ };
113
+ view: {
114
+ databases: string[];
115
+ services: string[];
100
116
  scalars: string[];
101
117
  };
102
- components: {
118
+ zone: {
103
119
  databases: string[];
104
120
  services: string[];
105
121
  scalars: string[];
106
122
  };
107
123
  }
108
- export declare const getDefaultFileScan: () => FileConventionScanResult;
109
- export interface AppScanResult {
124
+ export interface ScanResult {
110
125
  name: string;
111
126
  type: "app" | "lib";
112
127
  repoName: string;
113
128
  serveDomain: string;
114
- akanConfig: AppConfigResult;
115
129
  files: FileConventionScanResult;
116
130
  libDeps: string[];
117
131
  pkgDeps: string[];
118
132
  dependencies: string[];
119
- libs: {
120
- [key: string]: LibScanResult;
121
- };
122
133
  }
123
- export interface LibScanResult {
124
- name: string;
125
- type: "app" | "lib";
126
- repoName: string;
127
- serveDomain: string;
134
+ export interface AppScanResult extends ScanResult {
135
+ akanConfig: AppConfigResult;
136
+ }
137
+ export interface LibScanResult extends ScanResult {
128
138
  akanConfig: LibConfigResult;
129
- files: FileConventionScanResult;
130
- libDeps: string[];
131
- pkgDeps: string[];
132
- dependencies: string[];
133
- libs: {
134
- [key: string]: LibScanResult;
135
- };
136
139
  }
137
140
  export interface PkgScanResult {
138
141
  name: string;