Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support to typescript #29

Merged
merged 1 commit into from
Aug 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 9 additions & 15 deletions index.d.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@

export class Layer8Config {
ServiceProviderURL: string;
Layer8Scheme: string;
Layer8Host: string;
Layer8Port: string;
declare namespace _default {
export function testWASM(arg: any): Promise<any>;
export function persistenceCheck(): Promise<any>;
export function initEncryptedTunnel(...arg: any[]): Promise<any>;
export function checkEncryptedTunnel(): Promise<any>;
export function fetch(url: any, ...args: any[]): Promise<any>;
export function _static(url: any): Promise<any>;
export { _static as static };
}

export interface Layer8 {
testWASM(arg: any): Promise<any>,
persistenceCheck(): Promise<any>,
initEncryptedTunnel(config: Layer8Config): Promise<boolean>,
static(url: string): Promise<string>,
fetch(input: RequestInfo | URL, init?: RequestInit | undefined): Promise<Response>
}

export default _default;
Loading