axe-api 1.3.1 → 1.4.0-beta-1

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/bin/axe ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+
3
+ require("../cli/index").cli(process.argv);
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const dotenv_1 = __importDefault(require("dotenv"));
7
+ const path_1 = __importDefault(require("path"));
8
+ const index_1 = require("./index");
9
+ console.log("Axe API dev-kit (1.0.1)");
10
+ dotenv_1.default.config();
11
+ const server = new index_1.Server();
12
+ server.start(path_1.default.join(__dirname, "dev-kit"));
@@ -182,25 +182,10 @@ export interface IContext extends IRouteData {
182
182
  validator: IValidator;
183
183
  queryParser?: QueryService;
184
184
  params?: any;
185
- /**
186
- * @deprecated Use special hook type instead of IContext like IBeforeInsertContext
187
- */
188
185
  conditions?: IQuery;
189
- /**
190
- * @deprecated Use special hook type instead of IContext like IBeforeInsertContext
191
- */
192
186
  query?: Knex.QueryBuilder;
193
- /**
194
- * @deprecated Use special hook type instead of IContext like IBeforeInsertContext
195
- */
196
187
  result?: any;
197
- /**
198
- * @deprecated Use special hook type instead of IContext like IBeforeInsertContext
199
- */
200
188
  item?: any;
201
- /**
202
- * @deprecated Use special hook type instead of IContext like IBeforeInsertContext
203
- */
204
189
  formData?: any;
205
190
  }
206
191
  export interface IBeforeInsertContext extends IContext {
@@ -1,4 +1,4 @@
1
1
  declare const _default: {
2
- FetchPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ FetchPhase: (context: import("index").IContext) => Promise<void>;
3
3
  };
4
4
  export default _default;
@@ -1,7 +1,7 @@
1
1
  declare const _default: {
2
- ActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
4
- QueryPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
5
- ResponsePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ ActionPhase: (context: import("index").IContext) => Promise<void>;
3
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
4
+ QueryPhase: (context: import("index").IContext) => Promise<void>;
5
+ ResponsePhase: (context: import("index").IContext) => Promise<void>;
6
6
  };
7
7
  export default _default;
@@ -1,6 +1,6 @@
1
1
  declare const _default: {
2
- ActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
4
- QueryPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ ActionPhase: (context: import("index").IContext) => Promise<void>;
3
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
4
+ QueryPhase: (context: import("index").IContext) => Promise<void>;
5
5
  };
6
6
  export default _default;
@@ -1,6 +1,6 @@
1
1
  declare const _default: {
2
- RelationalPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- ResultPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
4
- SerializePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ RelationalPhase: (context: import("index").IContext) => Promise<void>;
3
+ ResultPhase: (context: import("index").IContext) => Promise<void>;
4
+ SerializePhase: (context: import("index").IContext) => Promise<void>;
5
5
  };
6
6
  export default _default;
@@ -1,5 +1,5 @@
1
1
  declare const _default: {
2
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- FetchPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
3
+ FetchPhase: (context: import("index").IContext) => Promise<void>;
4
4
  };
5
5
  export default _default;
@@ -1,4 +1,4 @@
1
1
  declare const _default: {
2
- PrepareActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ PrepareActionPhase: (context: import("index").IContext) => Promise<void>;
3
3
  };
4
4
  export default _default;
@@ -1,5 +1,5 @@
1
1
  declare const _default: {
2
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- FetchPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
3
+ FetchPhase: (context: import("index").IContext) => Promise<void>;
4
4
  };
5
5
  export default _default;
@@ -1,5 +1,5 @@
1
1
  declare const _default: {
2
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- FetchPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
3
+ FetchPhase: (context: import("index").IContext) => Promise<void>;
4
4
  };
5
5
  export default _default;
@@ -1,8 +1,8 @@
1
1
  declare const _default: {
2
- RelationalPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- ResultPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
4
- SerializePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
5
- PrepareGetPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
6
- GetPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ RelationalPhase: (context: import("index").IContext) => Promise<void>;
3
+ ResultPhase: (context: import("index").IContext) => Promise<void>;
4
+ SerializePhase: (context: import("index").IContext) => Promise<void>;
5
+ PrepareGetPhase: (context: import("index").IContext) => Promise<void>;
6
+ GetPhase: (context: import("index").IContext) => Promise<void>;
7
7
  };
8
8
  export default _default;
@@ -1,6 +1,6 @@
1
1
  declare const _default: {
2
- PreparePhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- ActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
4
- ResultPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ PreparePhase: (context: import("index").IContext) => Promise<void>;
3
+ ActionPhase: (context: import("index").IContext) => Promise<void>;
4
+ ResultPhase: (context: import("index").IContext) => Promise<void>;
5
5
  };
6
6
  export default _default;
@@ -1,5 +1,5 @@
1
1
  declare const _default: {
2
- ActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
3
- PrepareActionPhase: (context: import("../../Interfaces").IContext) => Promise<void>;
2
+ ActionPhase: (context: import("index").IContext) => Promise<void>;
3
+ PrepareActionPhase: (context: import("index").IContext) => Promise<void>;
4
4
  };
5
5
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "axe-api",
3
- "version": "1.3.1",
3
+ "version": "1.4.0-beta-1",
4
4
  "description": "AXE API is a simple tool to create Rest APIs quickly.",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -26,6 +26,9 @@
26
26
  }
27
27
  ],
28
28
  "license": "MIT",
29
+ "bin": {
30
+ "axe": "bin/axe"
31
+ },
29
32
  "scripts": {
30
33
  "build": "rm -rf build && tsc && rm -rf build/dev-kit",
31
34
  "build:watch": "tsc -w",
@@ -86,6 +89,8 @@
86
89
  "@typescript-eslint/eslint-plugin": "^7.0.1",
87
90
  "@typescript-eslint/parser": "^7.0.1",
88
91
  "babel-jest": "^29.7.0",
92
+ "colors": "^1.4.0",
93
+ "commander": "^12.0.0",
89
94
  "cors": "^2.8.5",
90
95
  "eslint": "^8.56.0",
91
96
  "eslint-config-standard": "^17.1.0",
@@ -105,9 +110,11 @@
105
110
  "pg": "^8.11.3",
106
111
  "prettier": "^3.2.5",
107
112
  "redis": "^4.6.13",
113
+ "rimraf": "^5.0.5",
108
114
  "robust-validator": "^1.1.0",
109
115
  "serve-static": "^1.15.0",
110
116
  "set-value": ">=4.1.0",
117
+ "shelljs": "^0.8.5",
111
118
  "sqlite3": "^5.1.7",
112
119
  "ts-node": "^10.9.2",
113
120
  "tsx": "^4.7.1",