@hg-ts/domain 0.1.50 → 0.1.52

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/.eslintcache CHANGED
@@ -1 +1 @@
1
- [{"/Volumes/Work/ts/hg/framework/packages/domain/src/base.aggregate.ts":"1","/Volumes/Work/ts/hg/framework/packages/domain/src/base.entity.ts":"2","/Volumes/Work/ts/hg/framework/packages/domain/src/identifiable.ts":"3","/Volumes/Work/ts/hg/framework/packages/domain/src/index.ts":"4"},{"size":503,"mtime":1685205227846,"results":"5","hashOfConfig":"6"},{"size":447,"mtime":1685202816250,"results":"7","hashOfConfig":"6"},{"size":65,"mtime":1658011993469,"results":"8","hashOfConfig":"6"},{"size":121,"mtime":1665300013439,"results":"9","hashOfConfig":"6"},{"filePath":"10","messages":"11","suppressedMessages":"12","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"rlxbb6",{"filePath":"13","messages":"14","suppressedMessages":"15","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"16","messages":"17","suppressedMessages":"18","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"19","messages":"20","suppressedMessages":"21","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Volumes/Work/ts/hg/framework/packages/domain/src/base.aggregate.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/domain/src/base.entity.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/domain/src/identifiable.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/domain/src/index.ts",[],[]]
1
+ [{"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/base.aggregate.js":"1","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/base.entity.js":"2","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/identifiable.js":"3","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/index.js":"4","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/eslint.config.mjs":"5","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/base.aggregate.ts":"6","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/base.entity.ts":"7","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/identifiable.ts":"8","/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/index.ts":"9"},{"size":617,"mtime":1746294562031,"results":"10","hashOfConfig":"11"},{"size":434,"mtime":1746294562028,"results":"12","hashOfConfig":"11"},{"size":117,"mtime":1746294562023,"results":"13","hashOfConfig":"11"},{"size":344,"mtime":1746294562038,"results":"14","hashOfConfig":"11"},{"size":59,"mtime":1736896000125,"results":"15","hashOfConfig":"11"},{"size":502,"mtime":1740592968043,"results":"16","hashOfConfig":"17"},{"size":447,"mtime":1736876770670,"results":"18","hashOfConfig":"17"},{"size":65,"mtime":1736876770670,"results":"19","hashOfConfig":"17"},{"size":121,"mtime":1736876770670,"results":"20","hashOfConfig":"17"},{"filePath":"21","messages":"22","suppressedMessages":"23","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1gtnk1i",{"filePath":"24","messages":"25","suppressedMessages":"26","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"27","messages":"28","suppressedMessages":"29","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"30","messages":"31","suppressedMessages":"32","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"33","messages":"34","suppressedMessages":"35","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"36","messages":"37","suppressedMessages":"38","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"i5df87",{"filePath":"39","messages":"40","suppressedMessages":"41","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"42","messages":"43","suppressedMessages":"44","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"45","messages":"46","suppressedMessages":"47","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/base.aggregate.js",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/base.entity.js",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/identifiable.js",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/dist/index.js",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/eslint.config.mjs",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/base.aggregate.ts",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/base.entity.ts",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/identifiable.ts",[],[],"/Users/atsapko/WebstormProjects/personnal/framework/packages/domain/src/index.ts",[],[]]
@@ -0,0 +1,2 @@
1
+
2
+ 
@@ -0,0 +1,2 @@
1
+
2
+ 
@@ -0,0 +1,9 @@
1
+
2
+ ℹ tests 0
3
+ ℹ suites 0
4
+ ℹ pass 0
5
+ ℹ fail 0
6
+ ℹ cancelled 0
7
+ ℹ skipped 0
8
+ ℹ todo 0
9
+ ℹ duration_ms 6.505708
@@ -11,7 +11,7 @@ class BaseAggregate extends base_entity_1.BaseEntity {
11
11
  value: params.id,
12
12
  configurable: false,
13
13
  enumerable: false,
14
- writable: false,
14
+ writable: true,
15
15
  });
16
16
  }
17
17
  }
@@ -1 +1 @@
1
- {"version":3,"file":"base.aggregate.js","sourceRoot":"","sources":["../src/base.aggregate.ts"],"names":[],"mappings":";;;AAAA,+CAA2C;AAG3C,MAAM,gBAAgB,GAAG,MAAM,CAAC,kBAAkB,CAAC,CAAC;AAEpD,MAAsB,aAA+B,SAAQ,wBAAkB;IAC3D,CAAC,gBAAgB,CAAC,CAAS;IAE9C,YAAsB,MAA4B;QACjD,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,gBAAgB,EAAE;YAC7C,KAAK,EAAE,MAAM,CAAC,EAAE;YAChB,YAAY,EAAE,KAAK;YACnB,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,KAAK;SACf,CAAC,CAAC;IACJ,CAAC;CACD;AAbD,sCAaC"}
1
+ {"version":3,"file":"base.aggregate.js","sourceRoot":"","sources":["../src/base.aggregate.ts"],"names":[],"mappings":";;;AAAA,+CAA2C;AAG3C,MAAM,gBAAgB,GAAG,MAAM,CAAC,kBAAkB,CAAC,CAAC;AAEpD,MAAsB,aAA+B,SAAQ,wBAAkB;IAC3D,CAAC,gBAAgB,CAAC,CAAS;IAE9C,YAAsB,MAA4B;QACjD,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,gBAAgB,EAAE;YAC7C,KAAK,EAAE,MAAM,CAAC,EAAE;YAChB,YAAY,EAAE,KAAK;YACnB,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,IAAI;SACd,CAAC,CAAC;IACJ,CAAC;CACD;AAbD,sCAaC"}
@@ -0,0 +1,3 @@
1
+ import config from '@hg-ts/linter';
2
+
3
+ export default config;
package/package.json CHANGED
@@ -1,29 +1,30 @@
1
1
  {
2
2
  "name": "@hg-ts/domain",
3
- "version": "0.1.50",
3
+ "version": "0.1.52",
4
4
  "main": "dist/index.js",
5
- "module": "dist-esm/index.js",
5
+ "exports": {
6
+ ".": "./dist/index.js"
7
+ },
6
8
  "repository": "git@gitlab.com:hyper-graph/framework.git",
7
9
  "scripts": {
8
- "prepack": "yarn build && yarn lint",
9
- "build": "hg build",
10
- "build:dev": "hg build:dev",
11
- "lint": "hg lint",
12
- "lint:fix": "hg lint:fix"
10
+ "prepack": "yarn build && yarn lint:ts",
11
+ "build": "tsc",
12
+ "build:dev": "tsc-watch",
13
+ "lint:ts": "lint-ts",
14
+ "lint:ts:fix": "lint-ts --fix",
15
+ "test": "node --test",
16
+ "test:dev": "yarn build:dev --onSuccess \"yarn test\""
13
17
  },
14
18
  "devDependencies": {
15
- "@hg-ts-config/eslint-config": "0.1.50",
16
- "@hg-ts-config/typescript": "0.1.50",
17
- "@hg-ts/cli": "0.1.50",
18
- "@hg-ts/types": "0.1.50",
19
- "@types/node": "20.8.7",
20
- "@typescript-eslint/eslint-plugin": "6.8.0",
21
- "@typescript-eslint/parser": "6.8.0",
22
- "eslint": "8.52.0",
23
- "reflect-metadata": "*",
24
- "tsc-watch": "6.0.4",
25
- "tslib": "2.6.2",
26
- "typescript": "5.2.2"
19
+ "@hg-ts-config/typescript": "0.1.52",
20
+ "@hg-ts/linter": "0.1.52",
21
+ "@hg-ts/types": "0.1.52",
22
+ "@types/node": "22.10.6",
23
+ "eslint": "9.18.0",
24
+ "reflect-metadata": "0.2.2",
25
+ "tsc-watch": "6.3.0",
26
+ "tslib": "2.8.1",
27
+ "typescript": "5.7.3"
27
28
  },
28
29
  "peerDependencies": {
29
30
  "reflect-metadata": "*",
@@ -13,7 +13,7 @@ export abstract class BaseAggregate<IdType = string> extends BaseEntity<IdType>
13
13
  value: params.id,
14
14
  configurable: false,
15
15
  enumerable: false,
16
- writable: false,
16
+ writable: true,
17
17
  });
18
18
  }
19
19
  }
package/tsconfig.json CHANGED
@@ -5,5 +5,5 @@
5
5
  "rootDir": "src",
6
6
  "outDir": "dist"
7
7
  },
8
- "exclude": ["dist", "dist-esm"]
8
+ "exclude": ["dist"]
9
9
  }
package/.eslintrc.json DELETED
@@ -1,3 +0,0 @@
1
- {
2
- "extends": "@hg-ts-config/eslint-config/.eslintrc.json"
3
- }
@@ -1,9 +0,0 @@
1
- import { BaseEntity } from './base.entity';
2
- import type { Identifiable } from './identifiable';
3
- declare const AGGREGATE_SYMBOL: unique symbol;
4
- export declare abstract class BaseAggregate<IdType = string> extends BaseEntity<IdType> {
5
- protected readonly [AGGREGATE_SYMBOL]: IdType;
6
- protected constructor(params: Identifiable<IdType>);
7
- }
8
- export {};
9
- //# sourceMappingURL=base.aggregate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.aggregate.d.ts","sourceRoot":"","sources":["../src/base.aggregate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,QAAA,MAAM,gBAAgB,eAA6B,CAAC;AAEpD,8BAAsB,aAAa,CAAC,MAAM,GAAG,MAAM,CAAE,SAAQ,UAAU,CAAC,MAAM,CAAC;IAC9E,SAAS,CAAC,QAAQ,CAAC,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE9C,SAAS,aAAa,MAAM,EAAE,YAAY,CAAC,MAAM,CAAC;CAUlD"}
@@ -1,15 +0,0 @@
1
- import { BaseEntity } from './base.entity';
2
- const AGGREGATE_SYMBOL = Symbol('AGGREGATE_SYMBOL');
3
- export class BaseAggregate extends BaseEntity {
4
- [AGGREGATE_SYMBOL];
5
- constructor(params) {
6
- super(params);
7
- Object.defineProperty(this, AGGREGATE_SYMBOL, {
8
- value: params.id,
9
- configurable: false,
10
- enumerable: false,
11
- writable: false,
12
- });
13
- }
14
- }
15
- //# sourceMappingURL=base.aggregate.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.aggregate.js","sourceRoot":"","sources":["../src/base.aggregate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAG3C,MAAM,gBAAgB,GAAG,MAAM,CAAC,kBAAkB,CAAC,CAAC;AAEpD,MAAM,OAAgB,aAA+B,SAAQ,UAAkB;IAC3D,CAAC,gBAAgB,CAAC,CAAS;IAE9C,YAAsB,MAA4B;QACjD,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,gBAAgB,EAAE;YAC7C,KAAK,EAAE,MAAM,CAAC,EAAE;YAChB,YAAY,EAAE,KAAK;YACnB,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,KAAK;SACf,CAAC,CAAC;IACJ,CAAC;CACD"}
@@ -1,7 +0,0 @@
1
- import type { Identifiable } from './identifiable';
2
- export declare abstract class BaseEntity<IdType = string> implements Identifiable<IdType> {
3
- readonly id: IdType;
4
- protected constructor(params: Identifiable<IdType>);
5
- equals<T extends BaseEntity<IdType>>(entity: T): boolean;
6
- }
7
- //# sourceMappingURL=base.entity.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.entity.d.ts","sourceRoot":"","sources":["../src/base.entity.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,8BAAsB,UAAU,CAAC,MAAM,GAAG,MAAM,CAAE,YAAW,YAAY,CAAC,MAAM,CAAC;IAChF,SAAgB,EAAE,EAAE,MAAM,CAAC;IAE3B,SAAS,aAAa,MAAM,EAAE,YAAY,CAAC,MAAM,CAAC;IAI3C,MAAM,CAAC,CAAC,SAAS,UAAU,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC,GAAG,OAAO;CAI/D"}
@@ -1,11 +0,0 @@
1
- export class BaseEntity {
2
- id;
3
- constructor(params) {
4
- this.id = params.id;
5
- }
6
- equals(entity) {
7
- return Object.getPrototypeOf(this).constructor === Object.getPrototypeOf(entity).constructor
8
- && this.id === entity.id;
9
- }
10
- }
11
- //# sourceMappingURL=base.entity.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.entity.js","sourceRoot":"","sources":["../src/base.entity.ts"],"names":[],"mappings":"AAEA,MAAM,OAAgB,UAAU;IACf,EAAE,CAAS;IAE3B,YAAsB,MAA4B;QACjD,IAAI,CAAC,EAAE,GAAG,MAAM,CAAC,EAAE,CAAC;IACrB,CAAC;IAEM,MAAM,CAA+B,MAAS;QACpD,OAAO,MAAM,CAAC,cAAc,CAAC,IAAI,CAAE,CAAC,WAAW,KAAK,MAAM,CAAC,cAAc,CAAC,MAAM,CAAE,CAAC,WAAW;eAC1F,IAAI,CAAC,EAAE,KAAK,MAAM,CAAC,EAAE,CAAC;IAC3B,CAAC;CACD"}
@@ -1,4 +0,0 @@
1
- export type Identifiable<IdType = string> = {
2
- id: IdType;
3
- };
4
- //# sourceMappingURL=identifiable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"identifiable.d.ts","sourceRoot":"","sources":["../src/identifiable.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,CAAC,MAAM,GAAG,MAAM,IAAI;IACxC,EAAE,EAAE,MAAM,CAAC;CACd,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=identifiable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"identifiable.js","sourceRoot":"","sources":["../src/identifiable.ts"],"names":[],"mappings":""}
@@ -1,5 +0,0 @@
1
- import '@hg-ts/types';
2
- export * from './identifiable';
3
- export * from './base.aggregate';
4
- export * from './base.entity';
5
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC"}
package/dist-esm/index.js DELETED
@@ -1,5 +0,0 @@
1
- import '@hg-ts/types';
2
- export * from './identifiable';
3
- export * from './base.aggregate';
4
- export * from './base.entity';
5
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC"}
package/tsconfig.esm.json DELETED
@@ -1,9 +0,0 @@
1
- {
2
- "extends": "@hg-ts-config/typescript/esm",
3
- "compilerOptions": {
4
- "baseUrl": "src",
5
- "rootDir": "src",
6
- "outDir": "dist-esm"
7
- },
8
- "exclude": ["dist", "dist-esm"]
9
- }