Closed romanran closed 5 years ago
I'm checking the plugins code and I think it works different then I thought. Also I made sure that window.nsWebViewBridge is available, in the webview script.
Hi @romanran
Thank you for the issue.
Two things comes to mind.
First are you sure the assets are bundle with your app? This requires a small modification to webpack.config.js
and is a very common cause for problems.
new CopyWebpackPlugin([
{ from: { glob: "fonts/**" } },
{ from: { glob: "**/*.jpg" } },
{ from: { glob: "**/*.png" } },
{ from: { glob: 'assets/**'} }, // add this
])
Secondly could you try the alpha version of the plugin? It has been updated to nativescript-6.x, but is in alpha because our own app is still on 5.4.x.
Yes, all other features are working, I'm sure of it. I switched to another plugin already so I won't check unfortunately. Thanks for help.
I'm using vue, everything works fine, but the events.
Which platform(s) does your issue occur on?
Please, provide the following version numbers that your issue occurs with:
node --version
to fetch it)Please, tell us how to recreate the issue in as much detail as possible.
app.3.js
alert('test') window.nsWebViewBridge.on('test', function(cos) { alert('test event') })
I'm getting the "test" string, console.log with positions is working, but the test event doesn't return alert message.