@adaas/a-utils 0.0.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.
Files changed (81) hide show
  1. package/.nvmrc +1 -0
  2. package/LICENSE +22 -0
  3. package/README.md +49 -0
  4. package/dist/index.d.ts +15 -0
  5. package/dist/index.js +26 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/src/constants/errors.constants.d.ts +65 -0
  8. package/dist/src/constants/errors.constants.js +74 -0
  9. package/dist/src/constants/errors.constants.js.map +1 -0
  10. package/dist/src/global/ASEID.class.d.ts +77 -0
  11. package/dist/src/global/ASEID.class.js +129 -0
  12. package/dist/src/global/ASEID.class.js.map +1 -0
  13. package/dist/src/global/A_Deferred.class.d.ts +8 -0
  14. package/dist/src/global/A_Deferred.class.js +19 -0
  15. package/dist/src/global/A_Deferred.class.js.map +1 -0
  16. package/dist/src/global/A_Entity.class.d.ts +49 -0
  17. package/dist/src/global/A_Entity.class.js +94 -0
  18. package/dist/src/global/A_Entity.class.js.map +1 -0
  19. package/dist/src/global/A_Error.class.d.ts +13 -0
  20. package/dist/src/global/A_Error.class.js +54 -0
  21. package/dist/src/global/A_Error.class.js.map +1 -0
  22. package/dist/src/global/A_Polyfills.d.ts +21 -0
  23. package/dist/src/global/A_Polyfills.js +123 -0
  24. package/dist/src/global/A_Polyfills.js.map +1 -0
  25. package/dist/src/global/A_ScheduleObject.class.d.ts +9 -0
  26. package/dist/src/global/A_ScheduleObject.class.js +38 -0
  27. package/dist/src/global/A_ScheduleObject.class.js.map +1 -0
  28. package/dist/src/global/A_ServerError.class.d.ts +13 -0
  29. package/dist/src/global/A_ServerError.class.js +57 -0
  30. package/dist/src/global/A_ServerError.class.js.map +1 -0
  31. package/dist/src/helpers/A_Common.helper.d.ts +32 -0
  32. package/dist/src/helpers/A_Common.helper.js +184 -0
  33. package/dist/src/helpers/A_Common.helper.js.map +1 -0
  34. package/dist/src/helpers/A_Schedule.helper.d.ts +6 -0
  35. package/dist/src/helpers/A_Schedule.helper.js +21 -0
  36. package/dist/src/helpers/A_Schedule.helper.js.map +1 -0
  37. package/dist/src/types/ASEID.types.d.ts +65 -0
  38. package/dist/src/types/ASEID.types.js +5 -0
  39. package/dist/src/types/ASEID.types.js.map +1 -0
  40. package/dist/src/types/A_Common.types.d.ts +59 -0
  41. package/dist/src/types/A_Common.types.js +3 -0
  42. package/dist/src/types/A_Common.types.js.map +1 -0
  43. package/dist/src/types/A_Entity.types.d.ts +13 -0
  44. package/dist/src/types/A_Entity.types.js +4 -0
  45. package/dist/src/types/A_Entity.types.js.map +1 -0
  46. package/dist/src/types/A_Error.type.d.ts +7 -0
  47. package/dist/src/types/A_Error.type.js +3 -0
  48. package/dist/src/types/A_Error.type.js.map +1 -0
  49. package/dist/src/types/A_Error.types.d.ts +7 -0
  50. package/dist/src/types/A_Error.types.js +3 -0
  51. package/dist/src/types/A_Error.types.js.map +1 -0
  52. package/dist/src/types/A_ScheduleObject.types.d.ts +9 -0
  53. package/dist/src/types/A_ScheduleObject.types.js +3 -0
  54. package/dist/src/types/A_ScheduleObject.types.js.map +1 -0
  55. package/dist/src/types/A_ServerError.types.d.ts +4 -0
  56. package/dist/src/types/A_ServerError.types.js +3 -0
  57. package/dist/src/types/A_ServerError.types.js.map +1 -0
  58. package/docs/a-logo-docs.png +0 -0
  59. package/index.ts +64 -0
  60. package/jest.config.ts +19 -0
  61. package/package.json +73 -0
  62. package/src/constants/errors.constants.ts +78 -0
  63. package/src/global/ASEID.class.ts +208 -0
  64. package/src/global/A_Deferred.class.ts +20 -0
  65. package/src/global/A_Entity.class.ts +134 -0
  66. package/src/global/A_Error.class.ts +75 -0
  67. package/src/global/A_Polyfills.ts +112 -0
  68. package/src/global/A_ScheduleObject.class.ts +53 -0
  69. package/src/global/A_ServerError.class.ts +70 -0
  70. package/src/helpers/A_Common.helper.ts +229 -0
  71. package/src/helpers/A_Schedule.helper.ts +25 -0
  72. package/src/types/ASEID.types.ts +86 -0
  73. package/src/types/A_Common.types.ts +111 -0
  74. package/src/types/A_Entity.types.ts +17 -0
  75. package/src/types/A_Error.types.ts +10 -0
  76. package/src/types/A_ScheduleObject.types.ts +9 -0
  77. package/src/types/A_ServerError.types.ts +7 -0
  78. package/tests/default.test.ts +160 -0
  79. package/tests/polyfill.test.ts +37 -0
  80. package/tsconfig.json +58 -0
  81. package/tslint.json +98 -0
package/tsconfig.json ADDED
@@ -0,0 +1,58 @@
1
+ {
2
+ "compileOnSave": false,
3
+ "compilerOptions": {
4
+ "outDir": "dist",
5
+ "strict": true,
6
+ "noImplicitAny": false,
7
+ "noFallthroughCasesInSwitch": true,
8
+ "downlevelIteration": true,
9
+ "strictFunctionTypes": true,
10
+ "strictNullChecks": true,
11
+ "strictPropertyInitialization": true,
12
+ "forceConsistentCasingInFileNames": true,
13
+ "resolveJsonModule": true,
14
+ "noErrorTruncation": true,
15
+ "jsx": "react",
16
+ "target": "es2015",
17
+ "module": "commonjs",
18
+ "moduleResolution": "node",
19
+ "allowSyntheticDefaultImports": true,
20
+ "esModuleInterop": true,
21
+ "noUnusedLocals": false,
22
+ "noUnusedParameters": false,
23
+ "removeComments": false,
24
+ "preserveConstEnums": true,
25
+ "sourceMap": true,
26
+ "baseUrl": ".",
27
+ "experimentalDecorators": true,
28
+ "skipLibCheck": true,
29
+ "typeRoots": [
30
+ "node_modules/@types"
31
+ ],
32
+ "paths": {
33
+ "@adaas/a-utils/constants/*": ["src/constants/*"],
34
+ "@adaas/a-utils/global/*": ["src/global/*"],
35
+ "@adaas/a-utils/types/*": ["src/types/*"],
36
+ "@adaas/a-utils/helpers/*": ["src/helpers/*"],
37
+ "@adaas/a-utils/decorators/*": ["src/decorators/*"]
38
+ },
39
+ "lib": [
40
+ "dom",
41
+ "esnext.asynciterable",
42
+ "es2015",
43
+ "es2016",
44
+ "es2017.object"
45
+ ]
46
+ },
47
+ "include": [
48
+ "src/**/*",
49
+ "tests/**/*",
50
+ "examples/**/*",
51
+ "index.ts"
52
+ ],
53
+ "exclude": [
54
+ "node_modules/**/*",
55
+ "dist/**/*",
56
+ "node_modules/@types/mocha/index.d.ts"
57
+ ]
58
+ }
package/tslint.json ADDED
@@ -0,0 +1,98 @@
1
+ {
2
+ "extends": [
3
+ "tslint-react",
4
+ "tslint-config-standard",
5
+ "tslint-microsoft-contrib",
6
+ "tslint-config-prettier"
7
+ ],
8
+ "rules": {
9
+ "array-bracket-spacing": [true, "never"],
10
+ "arrow-return-shorthand": true,
11
+ "no-backbone-get-set-outside-model": false,
12
+ "completed-docs": false,
13
+ "curly": [true, "ignore-same-line"],
14
+ "cyclomatic-complexity": [true, 24],
15
+ "eofline": true,
16
+ "export-name": false,
17
+ "function-name": false,
18
+ "import-name": false,
19
+ "import-spacing": true,
20
+ "interface-name": [true, "never-prefix"],
21
+ "jsx-alignment": false,
22
+ "jsx-boolean-value": false,
23
+ "jsx-curly-spacing": false,
24
+ "jsx-no-multiline-js": false,
25
+ "match-default-export-name": false,
26
+ "max-func-body-length": 200,
27
+ "member-access": [true, "no-public"],
28
+ "member-ordering": {"options": [{"order": "fields-first"}]},
29
+ "missing-jsdoc": false,
30
+ "mocha-no-side-effect-code": false,
31
+ "no-arg": true,
32
+ "no-bitwise": true,
33
+ "no-console": false,
34
+ "no-construct": true,
35
+ "no-default-export": false,
36
+ "no-duplicate-switch-case": true,
37
+ "no-duplicate-variable": true,
38
+ "no-empty-interface": false,
39
+ "no-eval": true,
40
+ "no-function-expression": false,
41
+ "no-http-string": false,
42
+ "no-implicit-dependencies": false,
43
+ "no-multiline-string": false,
44
+ "no-non-null-assertion": true,
45
+ "no-relative-imports": false,
46
+ "no-require-imports": {"severity": "warning"},
47
+ "no-reserved-keywords": false,
48
+ "no-return-await": true,
49
+ "no-single-line-block-comment": false,
50
+ "no-string-throw": true,
51
+ "no-submodule-imports": false,
52
+ "no-suspicious-comment": false,
53
+ "no-unsafe-any": false,
54
+ "no-unused-variable": false,
55
+ "no-var-requires": true,
56
+ "no-void-expression": false,
57
+ "object-curly-spacing": [true, "never"],
58
+ "ordered-imports": false,
59
+ "prefer-for-of": true,
60
+ "prefer-object-spread": true,
61
+ "prefer-type-cast": false,
62
+ "quotemark": [true, "single", "jsx-double", "avoid-escape"],
63
+ "semicolon": [true, "never"],
64
+ "strict-boolean-expressions": false,
65
+ "strict-type-predicates": false,
66
+ "ter-func-call-spacing": [true, "never"],
67
+ "trailing-comma": [true, "always"],
68
+ "type-literal-delimiter": false,
69
+ "typedef": false,
70
+ "typedef-whitespace": [
71
+ true,
72
+ {
73
+ "call-signature": "nospace",
74
+ "index-signature": "nospace",
75
+ "parameter": "nospace",
76
+ "property-declaration": "nospace",
77
+ "variable-declaration": "nospace"
78
+ },
79
+ {
80
+ "call-signature": "onespace",
81
+ "index-signature": "onespace",
82
+ "parameter": "onespace",
83
+ "property-declaration": "onespace",
84
+ "variable-declaration": "onespace"
85
+ }
86
+ ],
87
+ "unified-signatures": true,
88
+ "variable-name": false,
89
+ "whitespace": [
90
+ true,
91
+ "check-branch",
92
+ "check-operator",
93
+ "check-typecast",
94
+ "check-rest-spread",
95
+ "check-type-operator"
96
+ ]
97
+ }
98
+ }