doczjs / docz-plugin-css

This package makes it possible to use preprocessors and css modules on docz
https://docz.site
38 stars 32 forks source link

installed this plugin; errors immediately when running the site #25

Open robjac opened 5 years ago

robjac commented 5 years ago
ERROR

UNHANDLED REJECTION Unable to find plugin "gatsby-plugin-mdx". Perhaps you need to install its package?

  Error: Unable to find plugin "gatsby-plugin-mdx". Perhaps you need to install its package?

  - load.js:109 resolvePlugin
    [.docz]/[gatsby]/dist/bootstrap/load-plugins/load.js:109:11

  - load.js:153 processPlugin
    [.docz]/[gatsby]/dist/bootstrap/load-plugins/load.js:153:20

  - load.js:172
    [.docz]/[gatsby]/dist/bootstrap/load-plugins/load.js:172:20

  - Array.forEach

  - load.js:171 module.exports
    [.docz]/[gatsby]/dist/bootstrap/load-plugins/load.js:171:20

  - index.js:58 module.exports
    [.docz]/[gatsby]/dist/bootstrap/load-plugins/index.js:58:19

  - index.js:136 module.exports
    [.docz]/[gatsby]/dist/bootstrap/index.js:136:34

  - develop.js:380 async module.exports
    [.docz]/[gatsby]/dist/commands/develop.js:380:7

Do i need to install this as well? your instructions and examples do not detail this process.

robjac commented 5 years ago

Also, my site is already successfully reading and using .mdx

So this error is rather confusing.

robjac commented 5 years ago

I then ran yarn add gatsby-plugin-mdx

and started my docz site,

then:

 ERROR

UNHANDLED REJECTION Cannot read property 'forEach' of undefined

  TypeError: Cannot read property 'forEach' of undefined

  - index.js:59 AsyncFunction.createMdxAstCompiler
    [.docz]/[@mdx-js]/mdx/index.js:59:13

  - gen-mdx.js:87 genMDX
    [.docz]/[gatsby-plugin-mdx]/utils/gen-mdx.js:87:24

  - task_queues.js:55 runNextTicks
    internal/process/task_queues.js:55:5

  - timers.js:412 processImmediate
    internal/timers.js:412:9

  - mdx-loader.js:159 Object.module.exports
    [.docz]/[gatsby-plugin-mdx]/loaders/mdx-loader.js:159:28
zy941002 commented 4 years ago

I got the same error~

enric-jorda commented 4 years ago

The same for me, any solution?

trybick commented 4 years ago

I am also seeing error TypeError: Cannot read property 'forEach' of undefined once adding the docz-plugin-css. Any info appreciated

trybick commented 4 years ago

In my case, I found out this plugin is only for docz v1. With docz v2 there is a new way to do css preprocessors:

https://www.docz.site/docs/usage-with-css-preprocessors

robjac commented 4 years ago

@trybick thanks for sharing. Is this new documentation? I've had to put my project on hold because of a number of issues without any documentation ( but this could help! )

thanks again.