Skip to content

Running custom code in given properties #1006

Closed Answered by latonz
diedona asked this question in Q&A
Discussion options

You must be logged in to vote

As mentioned by @ichalyshev the Mapperly way to address this is by using before/after map code. You can do it in a separate mapper with UseStaticMapper, but you can also do it directly in the same mapper, doesn't matter to Mapperly.
IMO this is pretty clean/good readable code.
If you need to apply the same modification to several properties, #783 will come to help (not yet implemented).

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by diedona
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants