bitovi / documentjs

The sophisticated documentation engine
https://documentjs.com/
MIT License
598 stars 381 forks source link

Assumed steal.production.js path during build can be wrong #219

Closed daffl closed 9 years ago

daffl commented 9 years ago

Originally reporterd in https://github.com/donejs/place-my-order/issues/87. It throws the following error:

node_modules/documentjs/node_modules/q/q.js:126
                    throw e;
                    ^

Error: ENOENT: no such file or directory, lstat '/node_modules/documentjs/node_modules/steal/steal.production.js'
    at Error (native)

This is because Steal is installed in the node_modules of the project root. The solution is to use require.resolve in DocumentJS.