arvo-core 1.1.8 → 1.1.9

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,5 @@
1
1
  import { ArvoEventData, ArvoExtension, CloudEventContext, CloudEventExtension, OpenTelemetryExtension } from './types';
2
+ import { InferArvoEvent } from '../types';
2
3
  /**
3
4
  * Represents an ArvoEvent, which extends the CloudEvent specification.
4
5
  * @template TData - The type of the event data, extending ArvoEventData.
@@ -67,7 +68,7 @@ export default class ArvoEvent<TData extends ArvoEventData = ArvoEventData, TExt
67
68
  *
68
69
  * @returns A plain object representation of the ArvoEvent, including all fields and extensions.
69
70
  */
70
- toJSON(): Record<string, any>;
71
+ toJSON(): InferArvoEvent<typeof this>;
71
72
  /**
72
73
  * Converts the ArvoEvent to a JSON string.
73
74
  * @param [spacing=0] - The number of spaces to use for indentation in the resulting JSON string.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "arvo-core",
3
- "version": "1.1.8",
3
+ "version": "1.1.9",
4
4
  "description": "This core package contains all the core classes and components of the Arvo Event Driven System",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {