Docz: Module not found: Can't resolve 'docz-theme-default' in '/opt/build/repo/.docz/app'

Created on 23 Dec 2018  ·  4Comments  ·  Source: doczjs/docz

after upgrading docz to
from "docz": "^0.12.15" to "docz": "^0.13.5",

3:00:29 AM: ⠏ Creating production build
3:00:30 AM: 
3:00:30 AM: ✖  fatal                        Failed to compile.
3:00:30 AM: ./.docz/app/root.jsx
3:00:30 AM: Module not found: Can't resolve 'docz-theme-default' in '/opt/build/repo/.docz/app'
3:00:30 AM: error Command failed with exit code 1.
3:00:30 AM: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
3:00:30 AM: Caching artifacts

Most helpful comment

@pedronauck
Don't you think this should be mentioned in Getting started docs and after the main package is installed?

docz-theme-default should be added to peerDependencies of docz

All 4 comments

@capaj I had a similar issue after upgrading. In the version 0.12.17 there was a message that you should install docz-theme-default as devDependencies. That solved my problem.

So, either
npm install --save docz-theme-default
or
yarn add -D docz-theme-default

Hopefully, it fixes the issue.

If you look into release v0.12.7 you'll see that since this version you need to explicitly add docz-theme-default as dependency on your package to make it work :)

@samuherek thanks that works like a charm! Can't wait until docz will be 1.0.0-it's much easier when a major signifies changes such as these.

@pedronauck
Don't you think this should be mentioned in Getting started docs and after the main package is installed?

docz-theme-default should be added to peerDependencies of docz

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kachkaev picture kachkaev  ·  3Comments

bichotll picture bichotll  ·  3Comments

hayk94 picture hayk94  ·  3Comments

ssylvia picture ssylvia  ·  3Comments

ilyanoskov picture ilyanoskov  ·  3Comments