Created
February 25, 2020 16:51
-
-
Save deanohyeah/c45761d9bfdee0a00c33ba77de9a7c15 to your computer and use it in GitHub Desktop.
typescript declarations for parent application from npm module
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ./custom_types/performanceEntry' | |
declare global { | |
export interface PerformanceEntry { | |
transferSize: number, | |
encodedBodySize: number, | |
decodedBodySize: number, | |
responseStart: number, | |
responseEnd: number, | |
requestStart: number, | |
attribution: Array<any>, | |
} | |
} | |
export declare const PerformanceEntry: PerformanceEntry; | |
// index.d.ts | |
import wrapGraphqlRequest from './helpers/wrap_graphql_request'; | |
// type declared in another file | |
import { PerformanceMetricsConfigs } from './services/elastic_apm_rum'; | |
export { PerformanceMetricsUser } from './services/elastic_apm_rum'; | |
// this provides type dependencies to the parent application | |
export * from './custom_types/performanceEntry'; | |
// export api for the module | |
declare function initialize(initializeConfigs: PerformanceMetricsConfigs): undefined; | |
export { wrapGraphqlRequest, initialize as rumInitialize }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment