title: How to create a json object with input variable
body: <p>I want to create a JSON object with input variable. I have a 2 input field. when I click button i want to take input values and make a JSON object with that value. I cannot create a JSON object with entered value.</p>
  
  <p>I try that</p>
  
  <pre><code>//getting the value of input as a variable
  let id=document.querySelector("#id");
  let title=document.querySelector("#title");
  </code></pre>
  
  <p>first I try the below. it sends a blank value instead of variable string</p>
  
  <pre><code>var vObj= '{"id":'+id.value+',"title":'+title.value+'}'
  </code></pre>
  
  <p>I also try that to </p>
  
  <pre><code>var vObj = {"id":{},"v_title":{}, "v_category":{}};
  vObj.id=id.value;
  vObj.title=title.value;
  </code></pre>
  
  <p>tried that</p>
  
  <pre><code>let asd=id.value;
  let bsd=title.value;
  
  var vObj = {id:asd, title:bsd}
  </code></pre>
  
  <p>it returns a blank value instead of variable value.</p>
  
  <p>i am making a mistake that the trigger button has typo. i couldn't see that. sorry</p>