All things Shopify and commerce
Currently wanting this IndexFilter feature from Polaris but I'm not sure how to use it in javascript because it is documentated only on how to use in TypeScripts at the moment.
Current issue that I'm facing is how to convert this to javascript:
import type {IndexFiltersProps} from '@shopify/polaris'; const sortOptions: IndexFiltersProps['sortOptions'] = [ {label: 'Order', value: 'order asc', directionLabel: 'Ascending'}, {label: 'Order', value: 'order desc', directionLabel: 'Descending'}, {label: 'Customer', value: 'customer asc', directionLabel: 'A-Z'}, {label: 'Customer', value: 'customer desc', directionLabel: 'Z-A'}, {label: 'Date', value: 'date asc', directionLabel: 'A-Z'}, {label: 'Date', value: 'date desc', directionLabel: 'Z-A'}, {label: 'Total', value: 'total asc', directionLabel: 'Ascending'}, {label: 'Total', value: 'total desc', directionLabel: 'Descending'}, ];
can anyone knows how to use it in JSX?
Thanks in advance.
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024