Closed l0stpenguin closed 7 years ago
Hi Mevin,
I am traveling until next week, so I am less available to check things. However, I was able to run with webpack last time I checked (granted it was with NS 2.5). Thanks for the demo project, I will get back to you soon.
Cheers!
@mevinDhun I was able to reproduce with your sample project. However, since this seems to be an issue with the android runtime (see my addition to this issue, I don't think I have anything to change for now.
However, as a work around you can do the following:
getContacts
function instead of the getContactsWorker
index.js
in your node_modules/nativescript-contacts-lite/index.js
Then running npm run start-android-bundle
will work. I will leave this issue open for now and keep an eye out to see when the issues with web workers will be fixed.
@abhayastudios The getContacts
will block the UI and is not suitable for my app. Using webpack is not a must for me right now, hence i can skip it for android. I will wait for 778 to be resolved and then will try to integrate wepack on my android version.
Thanks
@abhayastudios Did you find any solution for getContactsWorker
to work on Android ?
According to 778 the issues with web workers was solved.
@alexandruantonica Indeed it is supposed to be released with NS 3.2. I haven't gotten around trying it yet in the @next build. Will update here when I get a chance.
Fixed in NS3.2 with bb9f85a020ca718622cae3ca163c635b5043d7d5 and nativescript-dev-webpack
v0.8.0.
Hi, i tried using your plugin with webpack but it fails on android.
To reproduce: Create a sample app based on default angular template: Add the webpack plugin + nativescript-contacts-lite + worker loader Add some codes using the web worker
Run the bundled project
Gradle fails at :asbg:generateBindings
According to #778, This occurs because the plugin loads the tns modules which are already in the vendor.ts. I even tried using android@next version but it still fails. Here is a sample project with minimalistic code to reproduce https://github.com/mevinDhun/nativescript-webpack-error-app
Is there any way to fix this?
Thanks