Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overrididing the default source code generation #112

Open
turboMaCk opened this issue Feb 23, 2021 · 0 comments
Open

Overrididing the default source code generation #112

turboMaCk opened this issue Feb 23, 2021 · 0 comments

Comments

@turboMaCk
Copy link
Member

Currently the only generation hooks are settings of a file path https://hackage.haskell.org/package/elm-street-0.1.0.4/docs/Elm-Generate.html#t:Settings

However this is highly inflexible. We should at least some of

  • provide ability to produce Text/String/Bytestring so it can be post-processed if needed or piped to any file (stdout)
  • make it possible to write the content to file descriptor (though I think above would be enough and better)
  • make it possible to extend default imports with custom imports for each type

This would make it possible to combine elm-street with hand written decoders and type as well as provide an ability to write working Elm which are not implemented by the library itself. Example: #111 This requires extending Types module with import Json.Decode.

@turboMaCk turboMaCk changed the title Allow for posibility to override default generation Overrididing the default source code generation Feb 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant