pixelstew / gatsby-paginate

A simple library for paginating posts in Gatsby js.
GNU General Public License v3.0
123 stars 26 forks source link

Added layout option to createPaginatedPages #28

Closed AlejandroHerr closed 6 years ago

AlejandroHerr commented 6 years ago

Added an optional parameter in createPaginatedPages for passing the name of the layout for this page when createPage is called.

camsloanftc commented 6 years ago

@pixelstew - Has this been released to NPM yet? I was trying to figure out why I couldn't pull in my layout, and then I inspected the nod_module code and I saw that these changes were not there yet. If not, could you possibly do a release?

camsloanftc commented 6 years ago

Also, I just pulled the code from Github instead of npm, in order to use the layout feature. I am now getting an error index is not defined when I run yarn develop.

ReferenceError: index is not defined

  - index.js:70 module.exports
    [consumer-website]/[gatsby-paginate]/src/index.js:70:3

  - gatsby-node.js:119 graphql.then.result
    /Users/cam.s/Documents/development/ecobee/consumer-website/gatsby-node.js:119:6

When I dig into the src file on line 72, should that actually read layout instead of index?