react-boilerplate: Can't include or use PouchDB
When I npm i pouchdb-browser --save
then in app.js:
import PouchDB from 'pouchdb-browser';
then webpack throws:
ERROR in ./~/debug/node.js
Module not found: Error: Can't resolve 'fs' in '/Users/epi/Projects/timecamp/v3.0/frontend/node_modules/debug'
@ ./~/debug/node.js 163:15-28
ERROR in ./~/debug/node.js
Module not found: Error: Can't resolve 'net' in '/Users/epi/Projects/timecamp/v3.0/frontend/node_modules/debug'
@ ./~/debug/node.js 170:16-30

I already tried (webpack.dev.babel.js):
node: {
fs: 'empty',
child_process: 'empty',
net: 'empty',
tls: 'empty',
},
but it does not help, same errors.
Could you please help me include PouchDB?
Best episage
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 17 (14 by maintainers)
Here you have https://github.com/mxstbr/react-boilerplate/pull/1161
It’s already there. Funny how quickly this thing changes… @mxstbr