1.3.7 • Published 6 years ago

gatsby-plugin-product-markdown-pages v1.3.7

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

gatsby-plugin-product-markdown-pages

A Gatsby source plugin for routing pages from product markdown files. Intended to be used with gatsby-source-product-markdown.

Install

With npm:

npm install --save gatsby-plugin-product-markdown-pages

With Yarn:

yarn add gatsby-plugin-product-markdown-pages

Implement

Basic usage:

// ./gatsby-config.js
module.exports = {
	plugins: [
		'gatsby-plugin-product-markdown-pages'
	]
}

This will generate pages based on your id and category properties if available. It will pass context variables id, lowerId, and upperId to product pages. For category pages, it will pass a category context variable. Your paths might look something like:

  • /product/id1
  • /product/id2
  • /category/fruits
  • /category/vegetables

Notes

  • Product variants will be automatically unpacked.
  • When querying your data, the id property will be changed to productId to differentiate between the product ID that's in your markdown file and the ID that GraphQL uses.
1.3.7

6 years ago

1.3.6

6 years ago

1.3.5

6 years ago

1.3.2

6 years ago

1.3.1

6 years ago

1.3.0

6 years ago

1.2.0

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago