-
Notifications
You must be signed in to change notification settings - Fork 63
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
Consider changing the JSON serialization for custom types #25
Comments
We discussed an concluded to change the current approach of: {
"$type": "typeTag",
"field1": "value1",
"field2": "value2"
} To this: ["typeTag", "value1", "value2"] |
I think it might be valuable for us to specify what this mapping looks like when we are coming from Frontend's that provide names for the fields such as in type Shape
= Rectangle Float Float
| Circle Float
| Prism Float Float type Shape =
| Rectangle of width : float * length : float
| Circle of radius : float
| Prism of width : float * float * height : float sealed abstract class Shape
object Shape {
case class Rectangle(width:Float, length:Float) extends Shape
case class Circle(radius:Float) extends Shape
case class Prism(width:Float, anonymous1:Float, height:Float) extends Shape
} |
It would be the same, right? This represents the constructor invocation not the declaration. |
That's what I wanted to get into actually. So in this case the declaration would have the field names, right? |
I think we should always translate to positional. The field names are just to make it more readable. That makes sense to capture in the type but probably not the value. It's debatable though. |
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors.
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68 * Report parse errors.
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68 * Report parse errors. * Updated docs. * Link to Elm package.
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68 * Report parse errors. * Updated docs. * Link to Elm package. * More documentation.
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68 * Report parse errors. * Updated docs. * Link to Elm package. * More documentation. * Moved out Literal and fixed codec. #75, #76 * Fix compile error. #75, #76 * Fix compile error. #75, #76 * Change naming convention for type tags. #77
* Added missing module declarations. #37 * Process only those modules that are reachable from exposed ones. Remove package path from module names. #21 * Renaming concepts based on review feedback. #41 * Moved Advanced module up a level. #43 * Removed unused unindent function. * Moved name to SDK. * Added missing module to SDK. * Partial implementation of value mapping. * Ignore all generated JS. * Change extra arg position and naming. #46, #25 * Change extra arg position and naming. #46, #25 * Removed remaining references to extra. #5 * Change extra arg position. #46, #25, #5 * Added more coverage. #46, #25, #5 * Changes suggested in the PR. #46, #25, #5 * Use more explicit names. * All patterns supported. * Pattern-match supported. * Added support for SDK operators. #52 * Fix compile errors. * Prepare Elm module publishing. #2 * Fix repo name. #2 * Support for let expressions. #54 * Simple join implementations. #64 * Refactoring to make the code more organized. * Refactoring to make the code more organized. * Prepare value mapping utils. #53 * More descriptive naming. * More descriptive naming. * Removed unused function * Better naming * Added utility function and removed unused one. * Added variable resolution. * Hooked up variable resolution and updated tests. #53 * Completed reference resolution. #53 * Added missing docs and refactored. #68 * Document and refactor driven by the goal to process Morphir using Morphir. #68 * Various fixes. #68 * Report parse errors. * Updated docs. * Link to Elm package. * More documentation. * Moved out Literal and fixed codec. #75, #76 * Fix compile error. #75, #76 * Fix compile error. #75, #76 * Change naming convention for type tags. #77 * Add documentation to types. #7 * Better docs.
No description provided.
The text was updated successfully, but these errors were encountered: