Constructor support in source model #62
frankfolsche
started this conversation in
Ideas
Replies: 2 comments
-
|
Hey, a bit late to the party here, sorry. I believe this is currently no longer an issue? I tested it out locally, and could assert it in an unit test. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Hi Tim, I've double check my example and update it to version 3.1.14, Two mistakes in the post that made it a bit un clear what my actuall issue is. I've updated the post. It's still the case that I can't build the abbove mentioned code, because my propties have a private set but the generated code does not use the constuctor but tries to set the private properties. |
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.
-
I like the library but one thing is stopping me from using Facet. That is the fact that all my domain models don't have public properties.
It's good practice to setup domain models this way to prevent unwanted changes, as the readme specifically states domain models "Facet is a C# source generator that lets you define lightweight projections (DTOs, API models, etc.) directly from your domain models, without writing boilerplate." I found it strange it's not supported.
Is this by design or is this something that could be added in the future?
The property or indexer 'Order.Id' cannot be used in this context because the set accessor is inaccessible'Beta Was this translation helpful? Give feedback.
All reactions