title: Correct way to modify a parents final argument from child in Flutter
body: <p>I am using redux (still learning about it) for my app made in Dart with Flutter. Firstly I am going to explain my code so you can understand better.</p>
  <p>I have this card model:</p>
  <pre><code>class CardModel {
    final List images;
    final int id;
    final AppType category;
    final bool status;
    final String title;
    final String description;
    final String location;
    final List&lt;String&gt; tags;
    // int userId;
  
    CardModel(
        {this.images,
        @required this.id,
        @required this.status,
        @required this.category,
        @required this.title,
        @required this.description,
        @required this.location,
        @required this.tags});
  
    CardModel copyWith({List images,
         int id,
         bool status,
         AppType category,
         String title,
         String description,
         String location,
         List&lt;String&gt; tags}){
           return CardModel(
             id: id ?? this.id,
             images: images ?? this.images,
             status: status ?? this.status,
             category: category ?? this.category,
             title: title ?? this.title,
             description: description ?? this.description,
             location: location ?? this.location,
             tags: tags ?? this.tags,
           );
         }
  }
  </code></pre>
  <p>It's immutable because my AppState has instances of this class.</p>
  <p>I have the following action:</p>
  <pre><code>class AddCard {
    final CardModel card;
  
    AddCard({this.card});
  }
  </code></pre>
  <p>Secondly, I have an upload page where I have 2 custom stateful widgets, one for the categories and status, and the other one with textfields for title, description, location, tags, etc... See the <a href="https://i.stack.imgur.com/ySa3X.png" rel="nofollow noreferrer">image</a>.</p>
  <p>So I am asking myself, how is the correct way of creating the new card?</p>
  <p>I've thought these 2 solutions:</p>
  <ol>
  <li>Create separate variables (which I don't like) for each card attribute in the upload page and passing the needed arguments to my custom widgets (but like some attributes are passed by value, so I must pass voidCallbacks to modify the value in the upload Page?).</li>
  <li>Create a CardModel empty variable and make use of the copyWith function everytime I want to modify a value. But then if I pass the card value to my custom widgets, they can't assign a new card (widget.card = widget.card.copyWith(fer:ergrgr);) because stateful widgets attributes are final. So I end up passing voidCallbacks again?</li>
  </ol>
  <p>I am trying to code as clean as possible, but can't figure out how can I do this... My 2 solutions seems dirty</p>
  <p><em>SideQuestion: Would make sense to make use of several patterns, like Redux for serializable data and scopeModel for short term data?</em></p>