@nathapp/nestjs-common 1.0.1-rc.18 → 1.0.1-rc.19

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/README.md CHANGED
@@ -1,4 +1,5 @@
1
1
  # Common NestJs Library
2
+ this is a NestJs Common Library, is is free to use on fastify and express
2
3
 
3
4
  # sample Default predefine Configuration on dotenv
4
5
 
@@ -1,2 +1,3 @@
1
1
  import JoiUtil, { JoiConfig } from "./utils/joi-util";
2
- export { JoiUtil, JoiConfig, };
2
+ import { validateUtil } from "./utils/validate-util";
3
+ export { JoiUtil, JoiConfig, validateUtil, };
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.JoiUtil = void 0;
3
+ exports.validateUtil = exports.JoiUtil = void 0;
4
4
  const joi_util_1 = require("./utils/joi-util");
5
5
  exports.JoiUtil = joi_util_1.default;
6
+ const validate_util_1 = require("./utils/validate-util");
7
+ Object.defineProperty(exports, "validateUtil", { enumerable: true, get: function () { return validate_util_1.validateUtil; } });
6
8
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/config/index.ts"],"names":[],"mappings":";;;AAAA,+CAAsD;AAGpD,kBAHK,kBAAO,CAGL"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/config/index.ts"],"names":[],"mappings":";;;AAAA,+CAAsD;AAIpD,kBAJK,kBAAO,CAIL;AAHT,yDAAqD;AAKnD,6FALO,4BAAY,OAKP"}
@@ -1,6 +1,7 @@
1
1
  export declare enum CommonExceptionCode {
2
2
  UNKNOWN_ERROR = -1,
3
3
  REQUEST_PARAMETER_ERROR = -2,
4
+ REQUEST_INVALID = -3,
4
5
  NOT_FOUND = 404,
5
6
  INTERNAL_ERROR = 501,
6
7
  USER_NOT_FOUND = 20000,
@@ -5,6 +5,7 @@ var CommonExceptionCode;
5
5
  (function (CommonExceptionCode) {
6
6
  CommonExceptionCode[CommonExceptionCode["UNKNOWN_ERROR"] = -1] = "UNKNOWN_ERROR";
7
7
  CommonExceptionCode[CommonExceptionCode["REQUEST_PARAMETER_ERROR"] = -2] = "REQUEST_PARAMETER_ERROR";
8
+ CommonExceptionCode[CommonExceptionCode["REQUEST_INVALID"] = -3] = "REQUEST_INVALID";
8
9
  CommonExceptionCode[CommonExceptionCode["NOT_FOUND"] = 404] = "NOT_FOUND";
9
10
  CommonExceptionCode[CommonExceptionCode["INTERNAL_ERROR"] = 501] = "INTERNAL_ERROR";
10
11
  CommonExceptionCode[CommonExceptionCode["USER_NOT_FOUND"] = 20000] = "USER_NOT_FOUND";
@@ -1 +1 @@
1
- {"version":3,"file":"app-exception-code.enum.js","sourceRoot":"","sources":["../../lib/exception/app-exception-code.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,mBAUX;AAVD,WAAY,mBAAmB;IAC7B,gFAAkB,CAAA;IAClB,oGAA4B,CAAA;IAC5B,yEAAe,CAAA;IACf,mFAAoB,CAAA;IACpB,qFAAsB,CAAA;IACtB,iFAAoB,CAAA;IACpB,qGAA8B,CAAA;IAC9B,mGAA6B,CAAA;IAC7B,2EAAiB,CAAA;AACnB,CAAC,EAVW,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAU9B"}
1
+ {"version":3,"file":"app-exception-code.enum.js","sourceRoot":"","sources":["../../lib/exception/app-exception-code.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,mBAWX;AAXD,WAAY,mBAAmB;IAC7B,gFAAkB,CAAA;IAClB,oGAA4B,CAAA;IAC5B,oFAAoB,CAAA;IACpB,yEAAe,CAAA;IACf,mFAAoB,CAAA;IACpB,qFAAsB,CAAA;IACtB,iFAAoB,CAAA;IACpB,qGAA8B,CAAA;IAC9B,mGAA6B,CAAA;IAC7B,2EAAiB,CAAA;AACnB,CAAC,EAXW,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAW9B"}
package/dist/index.d.ts CHANGED
@@ -1,9 +1,9 @@
1
+ export * from "./config";
2
+ export * from "./constant";
1
3
  export * from "./decorator";
2
4
  export * from "./exception";
3
5
  export * from "./i18n";
4
6
  export * from "./interceptor";
5
- export * from "./config";
6
- export * from "./constant";
7
7
  export * from "./logging";
8
- export * from "./serialize";
9
8
  export * from "./middleware";
9
+ export * from "./serialize";
package/dist/index.js CHANGED
@@ -14,13 +14,13 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./config"), exports);
18
+ __exportStar(require("./constant"), exports);
17
19
  __exportStar(require("./decorator"), exports);
18
20
  __exportStar(require("./exception"), exports);
19
21
  __exportStar(require("./i18n"), exports);
20
22
  __exportStar(require("./interceptor"), exports);
21
- __exportStar(require("./config"), exports);
22
- __exportStar(require("./constant"), exports);
23
23
  __exportStar(require("./logging"), exports);
24
- __exportStar(require("./serialize"), exports);
25
24
  __exportStar(require("./middleware"), exports);
25
+ __exportStar(require("./serialize"), exports);
26
26
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../lib/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,8CAA4B;AAC5B,yCAAuB;AACvB,gDAA8B;AAC9B,2CAAyB;AACzB,6CAA2B;AAC3B,4CAA0B;AAC1B,8CAA4B;AAC5B,+CAA6B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../lib/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,6CAA2B;AAC3B,8CAA4B;AAC5B,8CAA4B;AAC5B,yCAAuB;AACvB,gDAA8B;AAC9B,4CAA0B;AAC1B,+CAA6B;AAC7B,8CAA4B"}
@@ -1 +1 @@
1
- {"version":3,"file":"json-body.middleware.js","sourceRoot":"","sources":["../../lib/middleware/json-body.middleware.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA4D;AAC5D,6CAAmC;AAG5B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC7B,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAe;QAC9C,IAAA,kBAAI,GAAE,CAAC,GAAU,EAAE,GAAU,EAAE,IAAI,CAAC,CAAC;IACvC,CAAC;CACF,CAAA;AAJY,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;GACA,kBAAkB,CAI9B;AAJY,gDAAkB"}
1
+ {"version":3,"file":"json-body.middleware.js","sourceRoot":"","sources":["../../lib/middleware/json-body.middleware.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA4D;AAC5D,6CAAmC;AAM5B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC7B,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAe;QAC9C,IAAA,kBAAI,GAAE,CAAC,GAAU,EAAE,GAAU,EAAE,IAAI,CAAC,CAAC;IACvC,CAAC;CACF,CAAA;AAJY,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;GACA,kBAAkB,CAI9B;AAJY,gDAAkB"}
@@ -1 +1 @@
1
- {"version":3,"file":"raw-body.middleware.js","sourceRoot":"","sources":["../../lib/middleware/raw-body.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4D;AAE5D,0CAA0C;AAMnC,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAC5B,gBAAsB,CAAC;IAEhB,GAAG,CAAC,GAAY,EAAE,GAAkB,EAAE,IAAe;QAC1D,UAAU,CAAC,GAAG,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;CACF,CAAA;AANY,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;;GACA,iBAAiB,CAM7B;AANY,8CAAiB"}
1
+ {"version":3,"file":"raw-body.middleware.js","sourceRoot":"","sources":["../../lib/middleware/raw-body.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4D;AAE5D,0CAA0C;AAOnC,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAC5B,gBAAsB,CAAC;IAEhB,GAAG,CAAC,GAAY,EAAE,GAAkB,EAAE,IAAe;QAC1D,UAAU,CAAC,GAAG,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;CACF,CAAA;AANY,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;;GACA,iBAAiB,CAM7B;AANY,8CAAiB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nathapp/nestjs-common",
3
- "version": "1.0.1-rc.18",
3
+ "version": "1.0.1-rc.19",
4
4
  "description": "NestJs Common Library",
5
5
  "scripts": {
6
6
  "build": "rimraf dist && tsc -p tsconfig.json",
@@ -17,8 +17,6 @@
17
17
  },
18
18
  "devDependencies": {
19
19
  "@golevelup/ts-jest": "^0.3.7",
20
- "@nestjs/platform-express": "^9.0.0",
21
- "@nestjs/platform-fastify": "^9.0.0",
22
20
  "@nestjs/testing": "^9.4.3",
23
21
  "@types/body-parser": "^1.19.2",
24
22
  "@types/express": "^4.17.17",
File without changes
@@ -1 +0,0 @@
1
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/validation/index.ts"],"names":[],"mappings":""}