Skip to content

Commit d786dbe

Browse files
committed
feat: export utility functions from package root
- Add utils barrel file for internal module organization - Export getReportVersion, formatReport, getCurrentTimestamp as named exports - Enables clean imports: import { getReportVersion } from '@chainlink/data-streams-sdk'
1 parent a9cef2b commit d786dbe

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

typescript/src/index.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,15 @@ export type { MetricsSnapshot } from "./types/metrics";
6868
export { ConnectionStatus } from "./types/metrics";
6969
export * from "./types/errors";
7070

71+
// Utility Functions
72+
export {
73+
// Report utilities
74+
getReportVersion,
75+
formatReport,
76+
// Time utilities
77+
getCurrentTimestamp,
78+
} from "./utils";
79+
7180
// Constants
7281
export { DEFAULT_CONFIG } from "./defaultConfig";
73-
export { DEFAULT_TIMEOUT, DEFAULT_RETRY_ATTEMPTS, DEFAULT_RETRY_DELAY } from "./utils/constants";
82+
export { DEFAULT_TIMEOUT, DEFAULT_RETRY_ATTEMPTS, DEFAULT_RETRY_DELAY } from "./utils/constants";

typescript/src/utils/index.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// Barrel file for utils
2+
export * from "./constants";
3+
export * from "./time";
4+
export * from "./auth";
5+
export * from "./logger";
6+
export * from "./report";
7+
export * from "./origin-discovery";
8+
export * from "./validation";

0 commit comments

Comments
 (0)