GithubHelp home page GithubHelp logo

vuestorefront / vue-storefront Goto Github PK

View Code? Open in Web Editor NEW
10.5K 272.0 2.1K 126.35 MB

Alokai is a Frontend as a Service solution that simplifies composable commerce. It connects all the technologies needed to build and deploy fast & scalable ecommerce frontends. It guides merchants to deliver exceptional customer experiences quickly and easily.

Home Page: https://www.alokai.com

License: MIT License

JavaScript 3.01% TypeScript 96.87% Batchfile 0.01% Shell 0.01% Vue 0.10%
vue-storefront pwa headless vue ecommerce magento storefront mobile e-commerce nuxt

vue-storefront's Issues

CSS refactor

All CSS rules related to colors, font sizes and types, margins & paddings should be atomic. Now there are some components (e.g ColorButton.vue) with very simple and repeatable css rules which should be atomic.

Stock quantities synchro

At the moment, we're not synchronizing stock-quantities. For MVP it's even fine but eventually, we have to handle this issue.

I suggest adding a special method to https://github.com/DivanteLtd/mage2nosql - to synchronize the stocks separately.

Another case is to create webhook and Magento2 module to have this info almost real-time

How do we plan to support promo-rules and special prices

I believe we can get special_price from M2API - and it's the result of catalog promotion rules applied; but what to do with cart rules? It seems we need to send out each cart to Magento and calculate the prices there which does make no sense as we're trying to be platform agnostic :D

Email do not exist

[email protected] that is written in the github readme do not exist.
Final-Recipient: rfc822; [email protected]
Action: failed
Status: 5.0.0
Diagnostic-Code: smtp; 550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at

Please put a contact information for sending invitations to new members in the slack chat.

Fix Microcart

To display properly the items stored (step 1) and then style it (step 2h

Add "from" and "to" to price ranges in filters

Assigned to: @patrykpiston
Take a look at: /src/pages/Category.vue:118:

          if (attrToFilter !== 'price') {
            for (let option of res.aggregations['agg_terms_' + attrToFilter].buckets) {
              self.filters[attrToFilter].push({
                id: option.key,
                label: self._attributeOptionName(attrToFilter, option.key)
              })
            }
          } else { // special case is range filter for prices
            for (let option of res.aggregations['agg_range_' + attrToFilter].buckets) {
              self.filters[attrToFilter].push(option.key)
            }
          }
        }

The second part. To change the logic here we need to change the data model as well (the same file lines from 170):

      filters: { // filters should be set by category, and should be synchronized with magento
        color: [{'id': 165, 'label': 'red'}, {'id': 166, 'label': 'blue'}],
        size: [
            {'id': 50, 'label': 'XS'},
            {'id': 51, 'label': 'S'},
            {'id': 52, 'label': 'M'},
            {'id': 53, 'label': 'L'},
            {'id': 54, 'label': 'XL'}
        ],
        price: ['0.00 - 50.00', '50.01 - 100.00', '100.01 - 150.00', '150.01 and more']
      }
    }

we need to have something like:

        price: [ { from: 0, to: 50, label: '0 - 50PLN'} ... ] 

Does it make sense?

Shall we store categories in local collection (indexedDB) by slug.

It can be usefull because doing so we don't have to request server or service worker and have quick access for routing purposes (category page is more elegant then :) and supports numerous categories)

The question is about invalidation because it's getting more complicated than having simple service worker.

As for now we can invalidate the categories store each time it's populated by SW

Pin code authorisation

What do you think about extending the default login by another method known from airlines/booking.com etc

Pin code auth to get back your history of orders etc. It could be used to obtain the user token required for server synchronisation and in the result to get back all your customer data across many devices

How it sounds from UX and security perspective?

@karolbzik @filrak

Color options - limitation for Magento2

Regarding https://community.magento.com/t5/Programming-Questions/Magento2-customizing-swatch-values-through-web-api/td-p/27877

We're not currently able to get any swatch color options for selected option (for color attribute). We're getting only optionid (which is integer) and then label (which is string)

We assume as for now that label = hex repr. of color (can be named html color like "Red" as well).

We need to create an api extenshion to get the color swatch values or uploaded files

Add validator schema for breadcrumbs and slider

Under src/resource there are some json files to be used across app. Only order has it own validation schema under src/models

It's more for documentation purposes for now and to keep models logic coherent

We're using Ajv validator (take a look at store/modules/checkout.js):

const Ajv = require('ajv') // json validator
    const ajv = new Ajv()
    const validate = ajv.compile(require('../../models/order_schema.json'))

More on that: https://github.com/epoberezkin/ajv

To all core's: execute migrations and restore datadump

Hi All!

If you're using local vue-storefront-api as data api please execute the following commands after pulling out new code:

npm run migrate
npm run restore

New data dump with attributes is added, then new elastic schema is applied

Add an integration for newsletter subscription

Connected to #26. Newsletter claim should be stored in localstorage (you can add sth like "claims Collection" in /store/index.js:21)

Vue.prototype.$db = {
  ordersCollection: localForage.createInstance({
    name: 'shop',
    storeName: 'orders'
  }),

  categoriesCollection: localForage.createInstance({
    name: 'shop',
    storeName: 'categories'
  }),

  cartsCollection: localForage.createInstance({
    name: 'shop',
    storeName: 'carts'
  })
}

global.db = Vue.prototype.$db // localForage instance

Then add the logic to new store "user" added under store/modules.
Finally, adding new claim should execute SW trigger to send this claim out to the server as orders are synchronized (service-worker-ext.js for details), sth like this should be executed:

import * as sw from 'lib/sw'
sw.postMessage({ config: config, command: types.USER_NEWSLETTER_SIGNUP }) // add user to newsletter

in service-worker-ext.js

  if (event.data.command === 'user/NEWSLETTER_SIGNUP') {
...
}

And then - of course you should add new resource type under vue-storefront-api

Add search widget feature

Add the search widget feature.

Business scenarios:

  • As a Customer I can open search widget by clicking the button on the top;
  • As a Customer, I can type searched product (phrases like name of the product, SKU number, product category etc.) and as the result, I will instantly see the grid of products in search widget;
  • As a Customer, I can modify searched phrase and the product grid will be instantly updated;
  • As a Customer, I can click any product on the grid in search widget and move to the product card.

The design of the view:
search widget

Attribute dictionaries + filtering per category

To have properly worked faceted search in the categories we should synchronize the Attribute dictionaries, not only the product itself. We should have filter-attributes stored per category to properly build the filters. At MVP it would be even hard-coded and limited to "color" and "size" as it's for fashion.

Shouldn't we introduce domain-logic models into the frontend?

Right now the vuex stores returns PoJ (Plain Old Json ;)) objects. Kind of DTO's. So it's quite hard to add some logic or helper methods and it becomes more procedural development (with external helper classes) than OOP

Just thinking. The attribute data model is an example for this case

Use vuex ui-store instead of global events from event-bus in UI interactions

Now we have 3 events for toggling overlay, microcart and sidebar. It would be much better if we move all ui-related common events to one store. There is ui-store.js atm providing overlay, microcart and sidebar interactions but it's not used.

Definition of done: sidebar, overlay and microcart ui interactions are fired from ui-store.js not from global event bus

Add totals calculator to checkout/cart/order

Would be cool to have a totals calculator as Action(?) in /store/modules/cart. I believe it would be great to have such calculator in shared class/helper to use it on placed orders as well.

We should probably store the totals along with items - so we have to change indexedDb format of cart from simple list of items eventually to object (please consider changing /store/index.js where is the logic of syncing the cart vuex store with localForage)

404 page

/src/pages/Category.vue:22 - right now it's the Exception thrown when specific category page doesn't exist; need to be fixed - with global exception handler and custom exception class OR simply showing 404

We need "no result's message" anyway - when ES return no results

@filrak

Add behavior for selecting filters

Right now nothing is happening when specific filter is selected. We should add in Category.vue data.filters - something like:

filters: {
 price: { from:0, to: 50},
 color: 157,
 query: 'full text query'
}

and update it (and also mark the selection on UI) regarding filters

@karolbzik @patrykpiston

It's last thing to do to finish the filters

Support for nested categories

How do we support nested categories in navigation? Right now it's not supported (/src/themes/default/components/core/blocks/SidebarMenu/SidebarMenu.vue:16 need to be changed) - the categories object already consist of hierarchical data:

{  
  "_index":"vue_storefront_catalog",
  "_type":"category",
  "_id":"29",
  "_version":1,
  "_score":1,
  "_source":{  
    "id":29,
    "parent_id":2,
    "name":"Promotions",
    "is_active":false,
    "position":6,
    "level":2,
    "product_count":0,
    "children_data":[  
      {  
        "id":30,
        "parent_id":29,
        "name":"Women Sale",
        "is_active":true,
        "position":1,
        "level":3,
        "product_count":224,
        "children_data":[  

        ]
      },
      {  
        "id":31,
        "parent_id":29,
        "name":"Men Sale",
        "is_active":true,
        "position":2,
        "level":3,
        "product_count":39,
        "children_data":[  

        ]
      },
      {  
        "id":32,
        "parent_id":29,
        "name":"Pants",
        "is_active":true,
        "position":3,
        "level":3,
        "product_count":247,
        "children_data":[  

        ]
      },
      {  
        "id":33,
        "parent_id":29,
        "name":"Tees",
        "is_active":true,
        "position":4,
        "level":3,
        "product_count":192,
        "children_data":[  

        ]
      }
    ],
    "tsk":1505573191094
  }
}

Microcart component styling

We need to style Microcart component according to Figma.
Thiis task includes creating all components required for microcart to look like in Figma

Add product listing with horizontal filters

Add product listing with horizontal filters.
The view should use the same filters like on the already developed product listing with vertical filters: color, size, price.

The design of the view:
products listing with horizontal filters

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.