My current v-autocomplete
component is fetching an array of items from GrowthTasks.edges
to display.
<v-autocomplete label="Start Week"
:items="GrowthTasks.edges" item-text="node.growthStartDate" item-value="node.growthStartDate" dense></v-autocomplete>
The item-text
property retrieves the text using node.growthStartDate
, which is in a date format such as "2020-05-06".
Now, I want to convert it into a format like "2020-W19", and I know this can be achieved with moment("YYYY-[W]WW")
, but I'm unsure how to implement this with the item-text
property.
In essence, I would like the output in item-text
to be similar to:
{{ node.growthStartDate | moment("YYYY-[W]WW") }}
This particular code snippet works as intended. Any suggestions on how I can achieve this transformation?