title: Why should I use Redux in this example?
body: <p>So far, Redux hasn't made my life easier. Every time I add a component, I seem to unnecessarily create three files (action, constants, reducer) and think harder than necessary. But I believe there must be a clear advantage of using Redux that I am blind to. Let me take you to the following example.</p>
  
  <p><a href="https://i.stack.imgur.com/Xt3ZE.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Xt3ZE.png" alt="enter image description here"></a></p>
  
  <p><strong>Expected behavior:</strong></p>
  
  <p>The user can choose multiple items and add them to a shopping cart (POST to backend).</p>
  
  <p><strong>JQuery</strong></p>
  
  <p>This is what I naturally resort to, but I feel like I am doing it wrong if I use plain jQuery. Should I feel this way?</p>
  
  <pre><code>$(function() {
    $(".item").click(function(event) {
      $(event.target).toggleClass("selected");
    }
  
    $("button.submit").click(function() {
      var selectedItems = $(".item.selected");
      var itemIds = $.map(selectedItems, function(item) { return $(item).data("id") });
      $.post(some_url, {itemsToAdd: itemIds});
  });
  </code></pre>
  
  <p><strong>In React</strong></p>
  
  <p>I would do something like following:</p>
  
  <pre><code>ItemsContainer
    state: selectedItems
    functions: addItem, removeItem, saveCart
  
  Item
    state: isSelected
    props: addItem, removeItem
  </code></pre>
  
  <p><strong>In Redux</strong></p>
  
  <p>How can I do the same more easily? Maybe I shouldn't store <code>selectedItems</code> as a state inside <code>ItemsContainer</code> and inside a globalState?</p>