I can't really find the source code for this, but in the distributed package the Observable.d.ts could have a better definition for create. Currently it looks like this:
/**
* Creates a new cold Observable by calling the Observable constructor
* @static true
* @owner Observable
* @method create
* @param {Function} subscribe? the subscriber function to be passed to the Observable constructor
* @return {Observable} a new cold observable
*/
static create: Function;
Using it can throw an error, if you don't want implicit any's. I guess something like that would be better:
/**
* Creates a new cold Observable by calling the Observable constructor
* @static true
* @owner Observable
* @method create
* @param {Function} subscribe? the subscriber function to be passed to the Observable constructor
* @return {Observable} a new cold observable
*/
static create<T>(subscribe?: <R>(this: Observable<T>, subscriber: Subscriber<R>) => TeardownLogic): Observable<T>;
I can't really find the source code for this, but in the distributed package the
Observable.d.ts
could have a better definition forcreate
. Currently it looks like this:Using it can throw an error, if you don't want implicit
any
's. I guess something like that would be better: