title: Using JSON.NET to add a boolean property
body: <p>I have this JSON data</p>
  
  <pre><code>{
      "extensions": {
          "settings" : {
              "extension1": {
                  "property1": "value 1",
                  "property2": "value 2"
              }
          }
      }
  }
  </code></pre>
  
  <p>my goal is to add a new boolean property using JSON.NET to look like this</p>
  
  <pre><code>{
      "extensions": {
          "settings" : {
              "extension1": {
                  "property1": "value 1",
                  "property2": "value 2",
                  "bool_property": true
              }
          }
      }
  }
  </code></pre>
  
  <p>I only have this code and I'm stuck with AddAfterSelf and AddBeforeSelf</p>
  
  <pre><code>string pref = "path_of_the_preferences_file";
  string _pref = string.empty;
  using (StreamReader reader = new StreamReader(pref, Encoding.UTF8))
  {
      _pref = reader.ReadToEnd();
  }
  
  // REFORMAT JSON.DATA
  JObject json = JObject.Parse(_pref);
  var extension1 = json["extensions"]["settings"]["extension1"];
  </code></pre>
  
  <p>How do I insert the new boolean property "bool_property" ?</p>
  
  <p>Thanks</p>