Skip to content

Commit

Permalink
feat(js): sync import and set ProductCard globally
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
leomp12 committed Apr 2, 2020
1 parent 9fbe47e commit 1f9bbe7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions @ecomplus/storefront-template/template/js/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ import lozad from 'lozad'
import * as cloneDeep from 'lodash.clonedeep'
import * as merge from 'lodash.merge'
import Glide from '@glidejs/glide'

// import './lib/load-widgets'
import ProductCard from '@ecomplus/storefront-components/src/ProductCard.vue'

window._ = { cloneDeep, merge }
window.lozad = lozad
window.Glide = Glide
window.ProductCard = ProductCard

window.storefront = {
settings: window._settings,
Expand All @@ -31,6 +31,8 @@ window.storefront = {
...events
}

// import './lib/load-widgets'

setTimeout(() => {
import(/* webpackPreload: true */ './lib/fetch-info').catch(console.error)
}, 300)
Expand Down

0 comments on commit 1f9bbe7

Please sign in to comment.