You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using elm-codegen for the first time and found some inconsistent behavior. Let me know what you think!
Elm.file does not format the module name - so ["My", "module"] would generate an invalid elm module.
Elm.declarationdoes format the declaration name, but only by lowercasing the first letter.
Since both of these scenarios have some strict rules, maybe it would be worth to enforce them automatically?
An example solution using elmcraft/core-extra as dependency (for brevity sake):
Since these rules are compiled enforced, I don't think there would be backwards compatibility problems, right? Anything else would be causing compile errors anyway. This would, at worst, automatically fix those.
This could probably be applied to other scenarios that I haven't tried yet like type definitions.
I'm using elm-codegen for the first time and found some inconsistent behavior. Let me know what you think!
Elm.filedoes not format the module name - so["My", "module"]would generate an invalid elm module.Elm.declarationdoes format the declaration name, but only by lowercasing the first letter.Since both of these scenarios have some strict rules, maybe it would be worth to enforce them automatically?
An example solution using
elmcraft/core-extraas dependency (for brevity sake):Note