title: How to format date with Day.js in Vue.js
body: <p>I am building a web project with mainly Vue.js and am having problems with date time formatting.
  When getting data from my database (which is in datetime format), I get something like '2021-01-08T00:00:00'.
  Now is there a way to make Day.js accept such an input and convert that to either 'dd-mm-yyyy' or 'mm-dd-yyyy' or whatever format I want?
  I have tried:</p>
  <p><code>this.data.DateOfBirth = dayjs(e.dateOfBirth).format(&quot;dd-mm-yyyy&quot;);</code></p>
  <p>But it doesn't seem to work and throws an error warning like this on the browser console:</p>
  <blockquote>
  <p>The specified value &quot;Su-01-yyyy&quot; does not conform to the required
  format, &quot;yyyy-MM-dd&quot;.</p>
  </blockquote>
  <p>Many thanks!</p>