Replies: 1 comment
-
We're still working (slowly, as we have a product to ship 😄 ) on the topic. A good example of what we start to have, on typescript level, is types definitions and "algebraic data types" (Either, Left, Right) that looks like things provided by repos like:
Do the sveltekit team (working on TS support) is interested/planned this kind of modelisation ? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
typedData | serviceError
(it's more anEither
type, in fact)We want to wrap the fetch behavior to generalize the usage of those custom Error classes.
We use
fetch
on:Ideally we would like to have a single "fetchWrapper" lib, able to be typed (probably using generics) and handling errors as close as possible as the principles described above.
Question(s)
fallthrough
handling and the backed in svletekit error management)Beta Was this translation helpful? Give feedback.
All reactions