title: Convert date string to date with timezone using moment timezone js
body: <p>I need to convert a date string to PDT (Pacific Daylight Time) and the resutant datetime must be displayed in local time.</p>
  
  <p>I tried with</p>
  
  <pre><code>console.log(moment.tz("16:23:42 Sep 27, 2018 PDT", 'HH:mm:ss MMM DD, YYYY PDT',"PDT").format());
  </code></pre>
  
  <p>When I run the above code it displays </p>
  
  <pre><code>2018-09-27T16:23:42Z
  </code></pre>
  
  <p>Which is not the local time. The local time of its equivalent must be different. How do I get the local time of the date string specified.</p>
  
  <p>In otherwords, I mean to say like this <a href="https://forums.asp.net/t/1552114.aspx?Convert+Datetime+String+from+PDT+to+IST+local+time+datetime+string" rel="nofollow noreferrer">https://forums.asp.net/t/1552114.aspx?Convert+Datetime+String+from+PDT+to+IST+local+time+datetime+string</a></p>