import { ShopifyTaxonomyCategory } from '@daffodil/driver/shopify'
A category from Shopify's Standard Product Taxonomy assigned to a Product. Categories provide hierarchical classification through the ancestors field.
The ancestors field returns the parent chain from the immediate parent up to the root. Each ancestor category also includes its own ancestors.
The name field returns the localized category name based on the storefront's request language with shop locale fallbacks. If a translation isn't available for the resolved locale, the English taxonomy name is returned.
interface ShopifyTaxonomyCategory {
__typename: "TaxonomyCategory"
ancestors: ShopifyTaxonomyCategory[]
id: string
name: string
}
__typename "TaxonomyCategory" |
|---|
ancestors ShopifyTaxonomyCategory[] |
|---|
All parent nodes of the current taxonomy category. |
id string |
|---|
A static identifier for the taxonomy category. |
name string |
|---|
The localized name of the taxonomy category. |