GitHub

DaffProductMagentoDriverConfig

import { DaffProductMagentoDriverConfig } from '@daffodil/product/driver/magento'

An interface for providing @daffodil/product/driver/magento with necessary config values.

interface DaffProductMagentoDriverConfig {
  baseMediaUrl: string
  truncateUrl: boolean
  urlTruncationStrategy: (string: any) => string
}

Properties

baseMediaUrl
string

The fully-qualified base URL for media assets, such as product images. e.g. https://api.daff.io/media/

truncateUrl
boolean

Whether or not to attempt to truncate the product URL during the DaffMagentoProductService call. True by default.

urlTruncationStrategy
(string: any) => string

An optional custom function to truncate the URL. Defaults to truncate leading path segments, file extension, query params, and fragments.