Closed leolanavo closed 5 years ago
Looking into this - the main issue is the packaging dependencies. ts-nats is currently architected so that additional transports will plug into it. So some dependencies cannot leak through.
For now you can try
import {NatsError} from "ts-nats/lib/error";
If you have any suggestions let me know.
@leolanavo actually the solution is trivial - ts-nats just needs a simple export of the types that it imported and it does it. Putting a fix in.
Hi everyone,
It would be very awesome, if you exported the
NatsError
type, so you can properly type theMsgCallbacks
.This:
Could become this:
Way more beatiful, when you can type everything, and the code become more human friendly.