I created a brand new project using the regular command (Angular)
"dependencies": {
"@angular/animations": "~12.0.0",
"@angular/common": "~12.0.0",
"@angular/compiler": "~12.0.0",
"@angular/core": "~12.0.0",
"@angular/forms": "~12.0.0",
"@angular/platform-browser": "~12.0.0",
"@angular/platform-browser-dynamic": "~12.0.0",
"@angular/router": "~12.0.0",
"@nativescript/angular": "~12.0.0",
"@nativescript/core": "~8.0.0",
"@nativescript/theme": "~3.0.1",
"nativescript-insomnia": "^2.0.0",
"nativescript-texttospeech": "^3.0.1",
"nativescript-ui-listview": "^15.2.3",
"rxjs": "^6.6.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular/compiler-cli": "~12.0.0",
"@nativescript/android": "8.5.0",
"@nativescript/types": "~8.0.0",
"@nativescript/webpack": "beta",
"@ngtools/webpack": "~12.0.0",
"@types/lodash": "^4.14.191",
"typescript": "~4.2.0"
},
And I'm receiving the following error when I try to install plugin:
$ tns plugin add nativescript-ui-listview
# these WARNings are there no metter what I run, ever since I created my new project
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@ngtools/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^12.14.1 || >=14.0.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.14.0', npm: '8.7.0' }
npm WARN EBADENGINE }
Successfully installed plugin nativescript-ui-listview
Error:
Error executing Static Binding Generator: Couldn't find '/Users/myuser/project/platforms/android/build-tools/sbg-bindings.txt' bindings input file.
Most probably there's an error in the JS Parser execution.
You can run JS Parser with verbose logging by executing "node '/Users/myuser/project/platforms/android/build-tools/jsparser/js_parser.js' enableErrorLogging".
Detailed log here: /Users/myuser/project/platforms/android/build-tools/runSbg.log
I tried to run:
$ tns platform remove android
Gradle stop services...
Platform android successfully removed.
$ tns platform add android
Copying template files...
Platform android successfully added. v8.5.0
Now I tried to build the project, it builds correctly. But then I'm unable to import it to my project:
# app.module.ts
import { NativeScriptUIListViewModule } from "nativescript-ui-listview/angular";
# .. save ..
# Application builds OK on the device.
# app.module.ts: Adding the following row:
imports: [
...
NativeScriptUIListViewModule
...
]
# Crash log
Restarting application on device 94f27245...
System.err: An uncaught Exception occurred on "main" thread.
System.err: Unable to create application com.tns.NativeScriptApplication: com.tns.NativeScriptException: Error calling module function
System.err: Error: Angular JIT compilation failed: '@angular/compiler' not loaded!
System.err: - JIT compilation is discouraged for production use-cases! Consider AOT mode instead.
System.err: - Did you bootstrap using '@angular/platform-browser-dynamic' or '@angular/platform-server'?
System.err: - Alternatively provide the compiler with 'import "@angular/compiler";' before bootstrapping.
System.err: File: (file: src/webpack:/MyProject/webpack/bootstrap:27:0)
This is a brand new project, older projects works fine with nativescript-ui-listview so i'm not sure what's the issue here, any ideas where to start ?