Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple source filesystem error with typenames and routes #643

Open
Zyles opened this issue Sep 5, 2019 · 0 comments
Open

Multiple source filesystem error with typenames and routes #643

Zyles opened this issue Sep 5, 2019 · 0 comments

Comments

@Zyles
Copy link

Zyles commented Sep 5, 2019

Trying to use multiple source plugins with different typenames and root route results in an error because it tries to use the last typeName defined.

gridsome.config.js:
plugins: [
    {
      use: '@gridsome/source-filesystem',
      options: {
        path: 'content/*.md',
        typeName: 'ContentPage',
        route: '/:slug'
      }
    },
    {
      use: '@gridsome/source-filesystem',
      options: {
        path: 'content/info/*.md',
        typeName: 'InfoPage',
        route: '/:slug'
      }
    }
  ]

I want to use different templates for these pages but I do not want to use a route prefix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant