stoefln / node-native-ocr

Other
17 stars 11 forks source link

Hard dependency on Webpack when used with Electron #14

Open ryanbarr opened 2 years ago

ryanbarr commented 2 years ago

Due to non_webpack_require at index.js:11, there is a hard dependency on Webpack if you are attempting to use node-native-ocr with Electron.

In my scenario, I am using Vite which uses rollup.js. Due to __non_webpack_require__ being Webpack-specific, this makes the library unusable in my scenario.

I'm open to suggestions on shims, but would be interested in more permanent solutions in the library itself.

stoefln commented 1 year ago

@ryanbarr sorry for the late reply. Unfortunately I don't have any experience with vite or rollup.js.

Did you find a solution?