Saurabh Nanda

Results 231 comments of Saurabh Nanda

@mitchellwrosen IIUC you're basically walking down the TH representation of a Haskell data-type and transpiling it to Elm, right? I was thinking of changing the internals of `elm-bridge` to do...

> The newtype idiom is supported, in a clumsy way, as described here. The reason it is not done by default is that I liked it better that way :)...

Actually, just noticed a related issue. The type definitions and json-codecs of `Day` and `DiffTime` have not been generated. Is this expected?

@bartavelle any existing examples that do what you are suggesting? Also, is there any way to extend the code-gen (without patching this library) to use specific types on the Elm...

Going through the [documentation index](https://hackage.haskell.org/package/elm-bridge-0.4.3/docs/doc-index.html) I could only find one `*WithAlterations` function, i.e. [`makeModuleContentWithAlterations`](https://hackage.haskell.org/package/elm-bridge-0.4.3/docs/Elm-Module.html#v:makeModuleContentWithAlterations) -- is this the one that you are referring to? So, the idea is to call...

@bartavelle okay, I got something working, but I'm scratching my head over the difference in behaviour of "top-level" and "nested" types. Here's an example based on `Integer` (that is baked...

> Actually, just noticed a related issue. The type definitions and json-codecs of Day and DiffTime have not been generated. Is this expected? After reading through the code of [`recAlterType`](https://hackage.haskell.org/package/elm-bridge-0.4.3/docs/src/Elm-Module.html#recAlterType)...

> You might want to manually write the code for "contained" types, or want to stop at "primitive" types (such as Integer). If it worked recursively, you could not do...

> Did I understand correctly that you are wondering why you have to derive Bar and Baz explicitely? Yes, this is precisely what I'm wondering.

Consider another use-case, which is what I am struggling with currently: Haskell data-structure: ``` data User = User {userCreatedAt :: !UTCTime, userUpdatedAt :: !UTCTime, userEmail :: !Types.Email, userRefreshToken :: !Data.Text.Internal.Text,...