NativeScript / nativescript-angular

Integrating NativeScript with Angular
http://docs.nativescript.org/angular/tutorial/ng-chapter-0
Apache License 2.0
1.22k stars 241 forks source link

textChange event not working on IOS #2273

Open faisalansari20 opened 4 years ago

faisalansari20 commented 4 years ago

Hi Team,

I have text field in as below

` <TextField class="textfield" hint="Product Number" (textChange)="onChange($event)"

`

but onChange method get triggered only on Android and for IOS it is not working

NathanWalker commented 4 years ago

Can you share package.json?

faisalansari20 commented 4 years ago

ok. Here it is { "name": "@nativescript/template-hello-world-ng", "main": "main.js", "version": "7.0.2", "author": "NativeScript Team oss@nativescript.org", "description": "NativeScript Application", "license": "SEE LICENSE IN ", "publishConfig": { "access": "public" }, "keywords": [ "nativescript", "mobile", "angular", "{N}", "template" ], "repository": "", "bugs": { "url": "https://github.com/NativeScript/NativeScript/issues" }, "scripts": { "ngcc": "ngcc --properties es2015 module main --first-only", "postinstall": "npm run ngcc" }, "dependencies": { "@angular/animations": "~10.1.0", "@angular/common": "~10.1.0", "@angular/compiler": "~10.1.0", "@angular/core": "~10.1.0", "@angular/forms": "~10.1.0", "@angular/platform-browser": "~10.1.0", "@angular/platform-browser-dynamic": "~10.1.0", "@angular/router": "~10.1.0", "@nativescript/angular": "~10.1.0", "@nativescript/core": "~7.0.0", "@nativescript/theme": "~2.3.0", "@nstudio/nativescript-cardview": "^2.0.0", "nativescript-ui-listview": "^9.0.2", "reflect-metadata": "~0.1.12", "rxjs": "^6.6.0", "zone.js": "~0.11.1" }, "devDependencies": { "@angular/cli": "^10.1.1", "@angular/compiler-cli": "~10.1.0", "@nativescript/android": "7.0.0", "@nativescript/ios": "7.0.0", "@nativescript/schematics": "^10.1.0", "@nativescript/types": "~7.0.0", "@nativescript/webpack": "~3.0.0", "@ngtools/webpack": "~10.1.0", "@schematics/angular": "^10.1.1", "typescript": "~3.9.0" }, "private": "true", "readme": "NativeScript Application" }

NathanWalker commented 4 years ago

You can remove this as no longer needed in angular 10.1.x:

"scripts": {
"ngcc": "ngcc --properties es2015 module main --first-only",
"postinstall": "npm run ngcc"
},

Then make sure you've run ns clean in root of your project and then delete your webpack.config.js then npm i which will restore a fresh one. Then run the project.