title: How to dynamically add rows to a form in html when i click on add row button?
body: <pre><code>&lt;div class="row"&gt;
      &lt;div class="col-md-4"&gt;
          &lt;div class="form-group label-floating"&gt;
              &lt;label class="control-label"&gt;Act&lt;/label&gt;
              &lt;input type="text" class="form-control" v-model="act" &gt;
          &lt;/div&gt;
      &lt;/div&gt;
      &lt;div class="col-md-4"&gt;
          &lt;div class="form-group label-floating"&gt;
              &lt;label class="control-label"&gt;Section &lt;/label&gt;
              &lt;input type="text" class="form-control" v-model="section"&gt;
          &lt;/div&gt;
      &lt;/div&gt;
      &lt;button&gt;Add row&lt;/button&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>So, when I click on add button, i need to keep on adding the above row. How can I able to add this row when I click on add row button.</p>
  
  <p>I need to pass values as BOOKED UNDER :</p>
  
  <pre><code>[{
      act :,
      section:,
  }]
  </code></pre>
  
  <p>If I have more rows i need to pass values as comma seperated. I am weak in js and this is my first project having this kind of problem. How can I able to add values in this way.</p>
  
  <p>My vue js code is</p>
  
  <pre><code>addForm = new Vue({
      el: "#addForm",
      data: {
          bookedUnder:[],
          act: '',
          section:'',
      },
      methods: {
          handleSubmit: function(e) {
              var vm = this;
              data['otherNatureofOffense'] = //in the abve way
              $.ajax({
                  url: 'http://localhost:3000/record/add/f/',
                  data: data,
                  type: "POST",
                  dataType: 'json',
                  success: function(e) {
                      if (e.status) {
                          vm.response = e;
                          alert("success")
                      } else {
                          vm.response = e;
                          console.log(vm.response);
                          alert(" Failed") 
                      }
                  }
              });
              return false;
          }, 
      },
  });
  </code></pre>
  
  <p>Please help me to have a solution</p>