@@ -106,7 +106,7 @@ import { isServer } from '@vue-storefront/core/helpers'
106106import config from ' config'
107107import { htmlDecode } from ' @vue-storefront/core/filters/html-decode'
108108import { mapGetters } from ' vuex'
109- import moment from ' moment '
109+ import dayjs from ' dayjs '
110110
111111const composeInitialPageState = async (store , route , force = false ) => {
112112 try {
@@ -140,7 +140,7 @@ export default {
140140 return JSON .parse (this .post .blog_categories )
141141 },
142142 publishDate () {
143- return moment .unix (this .post .publish_date ).format (' MM/DD/YY h:mmA' )
143+ return dayjs .unix (this .post .publish_date ).format (' MM/DD/YY h:mmA' )
144144 },
145145 pageTitle () {
146146 const title = [this .post .title , this .$t (' Blog' )]
@@ -158,8 +158,8 @@ export default {
158158 'image': [
159159 '${ this .post .featured_image_file } '
160160 ],
161- 'datePublished': '${ moment .unix (this .post .publish_date ).format (' YYYY-MM-DD H:mm' )} ',
162- 'dateModified': '${ moment .unix (this .post .publish_date ).format (' YYYY-MM-DD H:mm' )} ',
161+ 'datePublished': '${ dayjs .unix (this .post .publish_date ).format (' YYYY-MM-DD H:mm' )} ',
162+ 'dateModified': '${ dayjs .unix (this .post .publish_date ).format (' YYYY-MM-DD H:mm' )} ',
163163 'author': {
164164 '@type': 'Person',
165165 'name': '${ this .post .author_name } '
@@ -211,7 +211,7 @@ export default {
211211 },
212212 methods: {
213213 dateToReadable (date ) {
214- return moment .unix (date).format (' MM/DD/YY h:mmA' )
214+ return dayjs .unix (date).format (' MM/DD/YY h:mmA' )
215215 }
216216 }
217217}
0 commit comments