Xstate: [4.7.2] The RxJS `from` throw an error if RxJS is imported before XState

Created on 3 Dec 2019  路  3Comments  路  Source: davidkpiano/xstate

Description

I see here that XState creates the Symbol.observable if it does not exists but RxJS does not

This led to the possibility that the RxJS ieff is executed before the XState one and so RxJS will continually try to find @@observable in the object.

Expected Result

If the Symbol.observable does not exists and @@observable should be returned.

Actual Result

If the Symbol.observable does not exists the symbol is created.

Reproduction

Unfortunately i'm not able to reproduce the bug on any codesandbox because they all use a polyfill before anything else.

Additional context

bug

Most helpful comment

Thanks for the report - going to fix this tomorrow and gonna also try to add tests to cover this.

All 3 comments

Thanks for the report - going to fix this tomorrow and gonna also try to add tests to cover this.

Thanks @Andarist, I was seeing the same behaviour.

Wasn't expecting a so fast answer, thanks a lot! 馃

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ifokeev picture ifokeev  路  3Comments

amelon picture amelon  路  3Comments

hnordt picture hnordt  路  3Comments

doup picture doup  路  3Comments

mattiamanzati picture mattiamanzati  路  3Comments