dchester / jsonpath

Query and manipulate JavaScript objects with JSONPath expressions. Robust JSONPath engine for Node.js.
MIT License
1.34k stars 215 forks source link

Can we modify jsonpath to work with React-Native #119

Open Anubhav-v opened 5 years ago

Anubhav-v commented 5 years ago

Unable to use jsonpath in react-native environment because of dependency on fs. Is it possible to remove this dependency?

coolguy001tv commented 5 years ago

Not only fs, but also some node lib. I am facing the error

error: bundling failed: Error: Unable to resolve module `assert` from `......\node_modules\jsonpath\lib\index.js`: Module `assert` does not exist in the Haste module map
realityking commented 5 years ago

If #94 were to be merged it would either fix this or at least come close to fixing this.

Anubhav-v commented 5 years ago

Thanks! Workaround for now - use the standalone jsonpath.min.js directly as a module inside the react-native project. Hope this usage doesn't violate any assumptions!

coolguy001tv commented 5 years ago

For me , I haven't started using this lib yet, so I just give up, LOL. But still thanks for your workaround. @Anubhav-v