tp / tsaga

Typesafe and lightweight way to write Redux-connected functions with asynchronous side-effects that are easily testable.
Apache License 2.0
8 stars 1 forks source link

Add expect library #55

Closed HenriBeck closed 5 years ago

HenriBeck commented 5 years ago

Closes #52

tp commented 5 years ago

I would expect expect to just throw nice errors, so it should then work with any test runner.

tp commented 5 years ago

@HenriBeck This line made me think it would modify the emitted code:

With --esModuleInterop two new helpers are generated importStar and importDefault for import * and import default respectively. For instance input like:

(from https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-7.html)

But then after reading this, I think it's fine to enabled it:

Note: The new behavior is added under a flag to avoid unwarranted breaks to existing code bases. We highly recommend applying it both to new and existing projects. For existing projects, namespace imports (import * as express from "express"; express();) will need to be converted to default imports (import express from "express"; express();).