Vue店面简介

下午好,我叫Andrey Soldatov,我们在Rosselkhozbank团队中正在开发与农业相关的有趣的新项目。作为其中某些解决方案的前端解决方案,我们决定使用有趣的开源解决方案Vue Storefront。在本文中,您可以熟悉此解决方案的关键功能。本文是Vue Storefront官方博客文章的翻译,此处提供原始文章

Vue Storefront 是一个具有广泛功能的相当复杂的解决方案。学习所有这些可能需要一些时间。在本文中,我将尝试在几分钟内向您解释关键概念,以向您展示开始使用Vue Storefront所需的一切。

什么是Vue店面?

Vue Storefront — backend- PWA () , Vue.js. , headless-, Vue Storefront eCommerce , PWA Magento, Shopify, BigCommerce, WooCommerce .

open source .

Vue Storefront:

  • mobile-first

  • MIT

  • « » ( SEO)

  • Offline

Vue Storefront, GitHub .

?

Vue Storefront backend- vue-storefront-api API- eCommerce backend-. vue-storefront-api . , , eCommerce , - - .

, ( , , Magento 1 -> 2), frontend.

API :

  • data pump ( mage2nosql) (, ..) eCommerce Vue Storefront ElasticSearch , vue-storefront-api. Vue Storefront. ElasticSearch backend- .

  • worker pool — ( , ..), vue-storefront-api backend .

, Vue Storefront backend .

backend (Magento 2, Magento 1, CoreShop, BigCommerce, WooCommerce), .

, .

?

Vue Storefront :

  • Vue Storefront Core (/core(https://github.com/DivanteLtd/vue-storefront/tree/master/core)) , Vue Storefront . : SSR, , . , , .

  • Vue Storefront Modules (/core/modules /src/modules) - eCommerce . (, , wish list, , ). / / , . .

  • Vue Storefront Themes (src/themes) - . / HTML- . Vue Storefront .

: — Vue Storefront Themes, , Vue Storefront Modules. Vue Storefront Core .

Vue Storefront .

: Vue Storefront.

Vue Storefront

:

这就是使VS与我们的演示后端一起工作所需要的。
, VS -.
  • frontend backend- ( , Vue Storefront).

  • frontend vue-storefront-api , -.

  • frontend vue-storefront-api, eCommerce backend.

- , "yarn installer" . "yarn dev" ( 3000 ). , , .

Vue Storefront

Vue Storefront (, , API, ..) , "/config". default.json .

local.json default.json, . local.json . Vue Storefront, .

Vue Storefront

Vue Storefront , — HTML CSS . - .

核心组件的业务逻辑可以使用Vue.js mixins轻松地嵌入到任何主题中
- Vue.js

- . Vue.js -. , , , , Microcart - ( ), (), mixins: [Microcart]. , , - . , .

- , package.json, config/local.jsonyarn”, Lerna ( monorepos).

Vue Storefront , . .

  • ( prod) sw-precache ( “/core/build/webpack.prod.sw.config.js”). Service Worker Application.

您可以在此处找到静态资源。 请注意,服务人员仅在生产模式下工作。
. , Service Worker prod .
  • IndexedDB Local Storage. , , , . “/core/lin./storage”.

, , . Vue Storefront .

?

, , , Vue Storefront! , .

4 Vue Storefront .




All Articles