Skip to content

Conversation

@JamesRoome
Copy link

@JamesRoome JamesRoome commented Jul 10, 2020

As mentioned by NickIliev the current version of the Android AppCompat library used by NativeScript is 1.0.2

I created a fork of fancy-advanced-webview that is using this version.

This solves my issue, I have been able to (finally!) update all my NativeScript libraries to latest.

@AdamAtri
Copy link

AdamAtri commented Nov 13, 2020

@JamesRoome I tried using your updated version 5.0.1, which does allow the plugin to fully build and the app to launch. however I get an error when trying openAdvancedUrl on Android:

An uncaught Exception occurred on "main" thread.
Calling js method onClick failed
Error: kotlin.KotlinNullPointerException
StackTrace:
openAdvancedUrl(file: node_modules/vt-nativescript-advanced-webview/advanced-webview.android.js:41:0)

which happens in a brand new app created with tns ver. 6.7.8

{
  "nativescript": {
    "id": "org.nativescript.testwebview",
    "tns-android": {
      "version": "6.5.0"
    },
    "tns-ios": {
      "version": "6.5.0"
    }
  },
  "main": "app.js",
  "description": "NativeScript Application",
  "license": "SEE LICENSE IN <your-license-filename>",
  "repository": "<fill-your-repository-here>",
  "dependencies": {
    "@nativescript/core": "~6.5.0",
    "@nativescript/theme": "~2.3.0",
    "tns-core-modules": "6.5.21",
    "nativescript-advanced-webview": "^5.0.1"
  },
  "devDependencies": {
    "nativescript-dev-webpack": "~1.5.0",
    "tns-platform-declarations": "~6.5.0",
    "typescript": "~3.8.3"
  },
  "gitHead": "20a65d338ae8f8911087ab6615b89363f864b07b",
  "readme": "NativeScript Application"
}

FYI - the demo app works as expected

@JamesRoome
Copy link
Author

JamesRoome commented Nov 13, 2020

@AdamAtri

For interest sake, I've attached the file I currently use. Github only allows .zip uploads, do you'll need to extract it to its .tgz version. Then the dependency will be:
"nativescript-advanced-webview": "file:3rdparty/nativescript-advanced-webview-5.0.1.tgz"

My current version info:

   "tns-ios": {
      "version": "6.5.2"
    },
    "tns-android": {
      "version": "6.5.3"
    }

Let me know how that goes.

nativescript-advanced-webview-5.0.1.tgz.zip

@mrzanirato
Copy link

Hello @JamesRoome I have a problem with the plugin. I receive this error:

ERROR ReferenceError: co is not defined

I think the reference is in advanced-webview.android.js

function init() {
co.fitcom.fancywebview.AdvancedWebView.AdvancedWebViewStatics.init(utils_1.ad.getApplicationContext(), true);
}

Can you help, please?

Thanks

Marco

@mrzanirato
Copy link

I'm using directly your file from local 3rd party files

@JamesRoome
Copy link
Author

Hi @mrzanirato

Sorry I haven't looked at this for nearly a year, we are currently moving off the NativeScript platform.

@mrzanirato
Copy link

Thanks anyway @JamesRoome ... I understand.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants