Added missing return type to on() methods. (johnny-five) (#13553)

This commit is contained in:
Santiago
2016-12-25 21:53:59 -05:00
committed by Andy
parent 37263290fe
commit b11fcff776

View File

@@ -118,9 +118,9 @@ export interface CompassOptions {
export declare class Compass {
constructor(option: CompassOptions);
on(event: string, cb: () => void): void;
on(event: "change", cb: () => void): void;
on(event: "data", cb: (data: any) => void): void;
on(event: string, cb: () => void): this;
on(event: "change", cb: () => void): this;
on(event: "data", cb: (data: any) => void): this;
}
export interface ESCOption {
@@ -153,9 +153,9 @@ export interface GyroMPU6050Option extends GyroGeneralOption {
export declare class Gyro {
constructor(option: GyroGeneralOption | GyroAnalogOption | GyroMPU6050Option);
on(event: string, cb: () => void): void;
on(event: "change", cb: () => void): void;
on(event: "data", cb: (data: any) => void): void;
on(event: string, cb: () => void): this;
on(event: "change", cb: () => void): this;
on(event: "data", cb: (data: any) => void): this;
recalibrate(): void;
}