@visma-digital-commerce/pwa-tag-list

1.0.1 • Public • Published

Visma Digital Commerce: Module Name

Module responsible for category tag list for a product.

Functionality

Adds a list of buttons with links to category that a given product is a part of.

Implementing

Add it to ProductFullDetail component. Example implementation using targetables:

const interceptComponent = component => {

    const ProductDetails = component;

    // Add an import statement to the productFullDetail.js file and
    // return the SingleImportStatement object
    const TagList = ProductDetails.addImport("TagList from 'tagList'");

    // Insert the TagList component after the product description and pass in the
    // new categoriesListData object added to the useProductFullDetails() hook
    ProductDetails.insertAfterJSX(
        '<RichContent html={productDetails.description} />',
        `<${TagList} categoriesListData={productDetails.categoriesListData} />`
    );
};

exports.interceptComponent = interceptComponent;

License

This module is proprietary software belonging to Visma Digital Commerce AS.

Readme

Keywords

none

Package Sidebar

Install

npm i @visma-digital-commerce/pwa-tag-list

Weekly Downloads

0

Version

1.0.1

License

MIT

Unpacked Size

10.8 kB

Total Files

18

Last publish

Collaborators

  • mirzashaukat
  • patryk.makowski.visma
  • kennethsusort
  • vismadigitalcommerce