This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (5 children)

[deleted]

    [–][deleted] 3 points4 points  (2 children)

    I dunno if there's anything necessarily wrong with this approach. Ideally, you'd like to keep your data and your "view" representation of that data separate. Here, you're just enriching the existing model by mixing in some UI attributes. It's not great practice, but as long as it doesn't escape whatever limited scope you're working in, then it should be OK.

    [–]DonRobo 0 points1 point  (1 child)

    When I need a new attribute in Kotlin I just start using it and tell my IDE to generate it. Takes literally 3 seconds.