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
Considering a case where I have a patient with 3 names, and I want to change the "use" of the second index in the list. Working with copyWith can be tricky.
Looking at examples in other elements where the depth can be even greater, the complexity of manipulating the elements can get worse.
The text was updated successfully, but these errors were encountered:
Your question is a good one, but unfortunately not one I have a great answer to. Freezed has many benefits, but since it is immutable you do run into these issues. I've considered trying to allow a search/edit function of the fhir_path package, but it would certainly require quite a bit of work.
There are times I've resorted to turning something into the Json map editing that, and then turning it back into the Dart class. It's definitely not the most elegant though.
I'm sorry I don't have a better solution at the moment. I'll leave this open though in case anyone else wants to chime in with suggestions.
Considering a case where I have a patient with 3 names, and I want to change the "use" of the second index in the list. Working with copyWith can be tricky.
Looking at examples in other elements where the depth can be even greater, the complexity of manipulating the elements can get worse.
The text was updated successfully, but these errors were encountered: