@bgord/bun 0.18.24 → 0.18.25

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 (34) hide show
  1. package/dist/modules/history/event-handlers/onHistoryClearedEvent.d.ts +2 -2
  2. package/dist/modules/history/event-handlers/onHistoryClearedEvent.d.ts.map +1 -1
  3. package/dist/modules/history/event-handlers/onHistoryClearedEvent.js +2 -2
  4. package/dist/modules/history/event-handlers/onHistoryPopulatedEvent.d.ts +2 -2
  5. package/dist/modules/history/event-handlers/onHistoryPopulatedEvent.d.ts.map +1 -1
  6. package/dist/modules/history/event-handlers/onHistoryPopulatedEvent.js +2 -2
  7. package/dist/modules/history/index.d.ts +1 -1
  8. package/dist/modules/history/index.d.ts.map +1 -1
  9. package/dist/modules/history/index.js +1 -1
  10. package/dist/modules/history/index.js.map +1 -1
  11. package/dist/modules/history/{repositories/history-repository.d.ts → ports/history-projection.d.ts} +2 -2
  12. package/dist/modules/history/ports/history-projection.d.ts.map +1 -0
  13. package/dist/modules/history/ports/history-projection.js +2 -0
  14. package/dist/modules/history/ports/history-projection.js.map +1 -0
  15. package/dist/modules/history/ports/index.d.ts +2 -0
  16. package/dist/modules/history/ports/index.d.ts.map +1 -0
  17. package/dist/modules/history/ports/index.js +2 -0
  18. package/dist/modules/history/ports/index.js.map +1 -0
  19. package/dist/tsconfig.tsbuildinfo +1 -1
  20. package/package.json +3 -3
  21. package/readme.md +2 -2
  22. package/src/modules/history/event-handlers/onHistoryClearedEvent.ts +3 -3
  23. package/src/modules/history/event-handlers/onHistoryPopulatedEvent.ts +3 -3
  24. package/src/modules/history/index.ts +1 -1
  25. package/src/modules/history/{repositories/history-repository.ts → ports/history-projection.ts} +1 -1
  26. package/src/modules/history/ports/index.ts +1 -0
  27. package/dist/modules/history/repositories/history-repository.d.ts.map +0 -1
  28. package/dist/modules/history/repositories/history-repository.js +0 -2
  29. package/dist/modules/history/repositories/history-repository.js.map +0 -1
  30. package/dist/modules/history/repositories/index.d.ts +0 -2
  31. package/dist/modules/history/repositories/index.d.ts.map +0 -1
  32. package/dist/modules/history/repositories/index.js +0 -2
  33. package/dist/modules/history/repositories/index.js.map +0 -1
  34. package/src/modules/history/repositories/index.ts +0 -1
@@ -1,4 +1,4 @@
1
1
  import * as Events from "../events";
2
- import * as Repos from "../repositories";
3
- export declare const onHistoryClearedEvent: (repository: Repos.HistoryRepositoryPort) => (event: Events.HistoryClearedEventType) => Promise<void>;
2
+ import * as Ports from "../ports";
3
+ export declare const onHistoryClearedEvent: (projection: Ports.HistoryProjectionPort) => (event: Events.HistoryClearedEventType) => Promise<void>;
4
4
  //# sourceMappingURL=onHistoryClearedEvent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"onHistoryClearedEvent.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/event-handlers/onHistoryClearedEvent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,KAAK,MAAM,iBAAiB,CAAC;AAEzC,eAAO,MAAM,qBAAqB,GAC/B,YAAY,KAAK,CAAC,qBAAqB,MAAY,OAAO,MAAM,CAAC,uBAAuB,kBAExF,CAAC"}
1
+ {"version":3,"file":"onHistoryClearedEvent.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/event-handlers/onHistoryClearedEvent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,KAAK,MAAM,UAAU,CAAC;AAElC,eAAO,MAAM,qBAAqB,GAC/B,YAAY,KAAK,CAAC,qBAAqB,MAAY,OAAO,MAAM,CAAC,uBAAuB,kBAExF,CAAC"}
@@ -1,4 +1,4 @@
1
- export const onHistoryClearedEvent = (repository) => async (event) => {
2
- await repository.clear(event.payload.subject);
1
+ export const onHistoryClearedEvent = (projection) => async (event) => {
2
+ await projection.clear(event.payload.subject);
3
3
  };
4
4
  //# sourceMappingURL=onHistoryClearedEvent.js.map
@@ -1,4 +1,4 @@
1
1
  import * as Events from "../events";
2
- import * as Repos from "../repositories";
3
- export declare const onHistoryPopulatedEvent: (repository: Repos.HistoryRepositoryPort) => (event: Events.HistoryPopulatedEventType) => Promise<void>;
2
+ import * as Ports from "../ports";
3
+ export declare const onHistoryPopulatedEvent: (projection: Ports.HistoryProjectionPort) => (event: Events.HistoryPopulatedEventType) => Promise<void>;
4
4
  //# sourceMappingURL=onHistoryPopulatedEvent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"onHistoryPopulatedEvent.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/event-handlers/onHistoryPopulatedEvent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,KAAK,MAAM,iBAAiB,CAAC;AAGzC,eAAO,MAAM,uBAAuB,GACjC,YAAY,KAAK,CAAC,qBAAqB,MAAY,OAAO,MAAM,CAAC,yBAAyB,kBAG1F,CAAC"}
1
+ {"version":3,"file":"onHistoryPopulatedEvent.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/event-handlers/onHistoryPopulatedEvent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,KAAK,MAAM,UAAU,CAAC;AAGlC,eAAO,MAAM,uBAAuB,GACjC,YAAY,KAAK,CAAC,qBAAqB,MAAY,OAAO,MAAM,CAAC,yBAAyB,kBAG1F,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import * as VO from "../value-objects";
2
- export const onHistoryPopulatedEvent = (repository) => async (event) => {
2
+ export const onHistoryPopulatedEvent = (projection) => async (event) => {
3
3
  const data = VO.HistoryParsed.parse(event.payload);
4
- await repository.append(data, event.createdAt);
4
+ await projection.append(data, event.createdAt);
5
5
  };
6
6
  //# sourceMappingURL=onHistoryPopulatedEvent.js.map
@@ -1,6 +1,6 @@
1
1
  export * as EventHandlers from "./event-handlers";
2
2
  export * as Events from "./events";
3
- export * as Repos from "./repositories";
3
+ export * as Ports from "./ports";
4
4
  export * as Services from "./services";
5
5
  export * as VO from "./value-objects";
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/history/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,gBAAgB,CAAC;AACxC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/history/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,EAAE,MAAM,iBAAiB,CAAC"}
@@ -1,7 +1,7 @@
1
1
  // TODO: tests
2
2
  export * as EventHandlers from "./event-handlers";
3
3
  export * as Events from "./events";
4
- export * as Repos from "./repositories";
4
+ export * as Ports from "./ports";
5
5
  export * as Services from "./services";
6
6
  export * as VO from "./value-objects";
7
7
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/modules/history/index.ts"],"names":[],"mappings":"AAAA,cAAc;AACd,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,gBAAgB,CAAC;AACxC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/modules/history/index.ts"],"names":[],"mappings":"AAAA,cAAc;AACd,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,EAAE,MAAM,iBAAiB,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import * as tools from "@bgord/tools";
2
2
  import * as VO from "../value-objects";
3
- export interface HistoryRepositoryPort {
3
+ export interface HistoryProjectionPort {
4
4
  append(data: VO.HistoryParsedType, createdAt: tools.TimestampType): Promise<void>;
5
5
  clear(subject: VO.HistoryParsedType["subject"]): Promise<void>;
6
6
  }
7
- //# sourceMappingURL=history-repository.d.ts.map
7
+ //# sourceMappingURL=history-projection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"history-projection.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/ports/history-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAEvC,MAAM,WAAW,qBAAqB;IACpC,MAAM,CAAC,IAAI,EAAE,EAAE,CAAC,iBAAiB,EAAE,SAAS,EAAE,KAAK,CAAC,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAElF,KAAK,CAAC,OAAO,EAAE,EAAE,CAAC,iBAAiB,CAAC,SAAS,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAChE"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=history-projection.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"history-projection.js","sourceRoot":"","sources":["../../../../src/modules/history/ports/history-projection.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export * from "./history-projection";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/modules/history/ports/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./history-projection";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/history/ports/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC"}