Date util documentation doesn't make sense
-
On this section https://quasar-framework.org/components/date-utils.html#Create it mentions that you can pass a third parameter, but there is nothing documented about what the second parameter is supposed to be. Can that be updated to be more clear?
-
As master Razvan always says to me, “go look at the source code!”
There are only two arguments to
buildDate
.export function buildDate (mod, utc) { return adjustDate(new Date(), mod, utc) }
I’ve sent in a PR to change “third” to “second” in the docs.
Scott
-
@toymachiner62 said in Date util documentation doesn't make sense:
On this section https://quasar-framework.org/components/date-utils.html#Create it mentions that you can pass a third parameter, but there is nothing documented about what the second parameter is supposed to be. Can that be updated to be more clear?
I’m also looking for the syntax to add ‘true’ to get the UTC date.
Even if I use adjustedDate and put in true, I’m still getting my local timezone, not UTC:
const newDate = new Date(2017, 10, 2) const adjustedDate = date.adjustDate(newDate, { year: 2010, month: 2 }, true)
I’m using extractDate…
const extractedBeginDate = date.extractDate(this.begDate, 'YYYY-MM-DD')