mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-06 09:19:08 +00:00
allignc commencts and add spaces
This commit is contained in:
12
types/signalr-no-jquery/index.d.ts
vendored
12
types/signalr-no-jquery/index.d.ts
vendored
@@ -4,7 +4,7 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.2
|
||||
|
||||
export function hubConnection(url?:string, options?: Options):Connection;
|
||||
export function hubConnection(url?: string, options?: Options): Connection;
|
||||
|
||||
export function signalR(url?: string, qs?: any, logging?: any): any;
|
||||
|
||||
@@ -12,7 +12,7 @@ interface Connection {
|
||||
id: string;
|
||||
proxies: { [hubName: string]: any };
|
||||
transport: { name: string, supportsKeepAlive: () => boolean };
|
||||
/**
|
||||
/**
|
||||
* Creates a new proxy object for the given hub connection that can be used to invoke
|
||||
* methods on server hubs and handle client method invocation requests from the server.
|
||||
*
|
||||
@@ -20,7 +20,7 @@ interface Connection {
|
||||
*/
|
||||
createHubProxy(hubName: string): Proxy;
|
||||
|
||||
start(options?:any, callback?:any):any
|
||||
start(options?: any, callback?: any): any;
|
||||
}
|
||||
|
||||
interface Proxy {
|
||||
@@ -29,21 +29,21 @@ interface Proxy {
|
||||
hubName: string;
|
||||
init(connection: Connection, hubName: string): void;
|
||||
hasSubscriptions(): boolean;
|
||||
/**
|
||||
/**
|
||||
* Wires up a callback to be invoked when a invocation request is received from the server hub.
|
||||
*
|
||||
* @param eventName The name of the hub event to register the callback for.
|
||||
* @param callback The callback to be invoked.
|
||||
*/
|
||||
on(eventName: string, callback: (...msg: any[]) => void): Proxy;
|
||||
/**
|
||||
/**
|
||||
* Removes the callback invocation request from the server hub for the given event name.
|
||||
*
|
||||
* @param eventName The name of the hub event to unregister the callback for.
|
||||
* @param callback The callback to be invoked.
|
||||
*/
|
||||
off(eventName: string, callback: (...msg: any[]) => void): Proxy;
|
||||
/**
|
||||
/**
|
||||
* Invokes a server hub method with the given arguments.
|
||||
*
|
||||
* @param methodName The name of the server hub method.
|
||||
|
||||
@@ -11,4 +11,5 @@ hubProxy.on('message', (message) => {
|
||||
// connect
|
||||
connection.start({ jsonp: true })
|
||||
.done(() => { console.log('Now connected, connection ID=' + connection.id); })
|
||||
.fail(() => { console.log('Could not connect'); });
|
||||
.fail(() => { console.log('Could not connect'); });
|
||||
|
||||
Reference in New Issue
Block a user