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

TypeError in Scheduler #3309

Closed
NiKlimenko opened this issue Feb 11, 2018 · 2 comments
Closed

TypeError in Scheduler #3309

NiKlimenko opened this issue Feb 11, 2018 · 2 comments

Comments

@NiKlimenko
Copy link

NiKlimenko commented Feb 11, 2018

RxJS version: 5.5.6

Code to reproduce:

import {observeOn} from 'rxjs/operators/observeOn';
import {Scheduler} from 'rxjs/Rx';

someObservable.pipe(
     observeOn(Scheduler.asap)
   )
     .subscribe(() => {});

Expected behavior:
Should work correctly, without compilation errors.

Actual behavior:

ERROR in node_modules/rxjs/scheduler/VirtualTimeScheduler.d.ts(24,15): error TS2416: Property 'work' in type 'VirtualAction<T>' is not assignable to the same property in base type
'AsyncAction<T>'.
  Type '(this: VirtualAction<T>, state?: T | undefined) => void' is not assignable to type '(this: AsyncAction<T>, state?: T | undefined) => void'.
    The 'this' types of each signature are incompatible.
      Type 'AsyncAction<T>' is not assignable to type 'VirtualAction<T>'.
        Property 'index' is missing in type 'AsyncAction<T>'.

Additional information:
TypeScript 2.7

@kwonoj
Copy link
Member

kwonoj commented Feb 11, 2018

Dupe of #3031 .

@kwonoj kwonoj closed this as completed Feb 11, 2018
@lock
Copy link

lock bot commented Jun 6, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants