Comments (12)
downgrade ngx-custom-validators to version 8.0.0 is worked fine for me
from ngx-custom-validators.
Angular 10.0.1
Error occurred when applying [min] or [max] to input field.
<input name="validity"
[(ngModel)]="insurancePlan.validity"
#validity="ngModel"
type="text"
class="form-control"
[class.is-invalid]="validity.touched && validity.errors"
[placeholder]="'INSURANCE_PLAN.VALIDITY' | translate"
[min]="1"
[max]="99999"
[pattern]="appConstant.positiveNumRegex">
Stacktrace:
core.js:4073 ERROR TypeError: Cannot read property 'firstCreatePass' of null
at providersResolver (core.js:27050)
at Object.definition.providersResolver (core.js:27382)
at resolveDirectives (core.js:7918)
at elementStartFirstCreatePass (core.js:13866)
at Module.ɵɵelementStart (core.js:13904)
at InsurancePlanPricingTableComponent_mat_tab_group_10_mat_cell_11_Template (insurance-plan-pricing-table.component.html:86)
at executeTemplate (core.js:7364)
at renderView (core.js:7173)
at TemplateRef.createEmbeddedView (core.js:10092)
at ViewContainerRef.createEmbeddedView (core.js:10161)
from ngx-custom-validators.
Same also in my case. If you use version 8.0.0 then it will compile successfully without any error.
from ngx-custom-validators.
I am getting similar error for range directive
vendor.js:18233 ERROR TypeError: Cannot read property 'firstCreatePass' of null
at providersResolver (vendor.js:311619)
at Object.definition.providersResolver (vendor.js:311951)
at resolveDirectives (vendor.js:22021)
at elementStartFirstCreatePass (vendor.js:27969)
at ɵɵelementStart (vendor.js:28007)
at Module.ɵɵelement (vendor.js:28082)
at xComponent_kendo_dialog_2_ng_template_10_ng_template_38_Template (main.js:12593)
at executeTemplate (vendor.js:21481)
at renderView (vendor.js:21290)
at TemplateRef.createEmbeddedView (vendor.js:24195)
Also in visual studio code, I see this warning...
Can't bind to 'range' since it isn't a known property of 'x'.
- If 'x' is an Angular component and it has 'range' input, then verify that it is part of this module.
- If 'x' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
- To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.ng
from ngx-custom-validators.
Released with 10.0.0, please reopen the issue if necessary.
from ngx-custom-validators.
Same here...here is the stack trace I get in VS Code if it helps:
Type 'import("C:/app-dev/cures/git/cures-ui/node_modules/ngx-custom-validators/node_modules/@angular/forms/forms").ValidatorFn' is not assignable to type 'import("C:/app-dev/cures/git/cures-ui/node_modules/@angular/forms/forms").ValidatorFn'. Types of parameters 'control' and 'control' are incompatible. Type 'import("C:/app-dev/cures/git/cures-ui/node_modules/@angular/forms/forms").AbstractControl' is not assignable to type 'import("C:/app-dev/cures/git/cures-ui/node_modules/ngx-custom-validators/node_modules/@angular/forms/forms").AbstractControl'. Types of property 'validator' are incompatible. Type 'import("C:/app-dev/cures/git/cures-ui/node_modules/@angular/forms/forms").ValidatorFn' is not assignable to type 'import("C:/app-dev/cures/git/cures-ui/node_modules/ngx-custom-validators/node_modules/@angular/forms/forms").ValidatorFn'. Types of parameters 'control' and 'control' are incompatible. Type 'import("C:/app-dev/cures/git/cures-ui/node_modules/ngx-custom-validators/node_modules/@angular/forms/forms").AbstractControl' is not assignable to type 'import("C:/app-dev/cures/git/cures-ui/node_modules/@angular/forms/forms").AbstractControl'. Types have separate declarations of a private property '_parent'.
from ngx-custom-validators.
I have the same error after update to angular 10
core.js:4073 ERROR TypeError: Cannot read property 'firstCreatePass' of null
at providersResolver (core.js:27050)
at Object.definition.providersResolver (core.js:27382)
at resolveDirectives (core.js:7918)
at elementStartFirstCreatePass (core.js:13866)
at ɵɵelementStart (core.js:13904)
at ɵɵelement (core.js:13979)
at FormValidationComponent_Template (template.html:83)
at executeTemplate (core.js:7364)
at renderView (core.js:7173)
at renderComponent (core.js:8431)
<input class="form-control" type="text" placeholder="digits" ngModel name="digits" #digits="ngModel" digits/>
Is there any solution to that???
from ngx-custom-validators.
@felixng1028 Thanks, it's working.
I hope this package would be updated soon.
from ngx-custom-validators.
We are experiencing the same problem after updating Angular to v10 (kubermatic/dashboard#2456).
from ngx-custom-validators.
downgrade ngx-custom-validators to version 8.0.0 is worked fine for me
Thanks, it worked perfectly
from ngx-custom-validators.
Same error after upgrading to angular 11. Using ngx-validators@10.
Test snippet:
<input type="number" matInput required step="1" [min]="0" [max]="var1" [(ngModel)]="var2" name="name" #model="ngModel">
from ngx-custom-validators.
thank you it solved
from ngx-custom-validators.
Related Issues (20)
- Cannot read property 'firstCreatePass' of null - After update to angular 10 HOT 5
- [Feature request] Validator to check if a value is included (or not) in an array HOT 3
- ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value for 'error': 'null' HOT 3
- ERROR in Symbol ArrayLengthValidator declared in.. Error after install and import the module HOT 1
- CustomValidator.includedIn does not exist
- Cannot read property 'firstCreatePass' of null HOT 10
- Angular 11 Update HOT 2
- Angular version table HOT 2
- v11 Publish Issue HOT 2
- Error: Please add a @NgModule annotation
- Cannot read property 'parent' of undefined
- equalControl.updateValueAndValidity is not a function
- Beyond version 8.0.0 is not building with Angular 10+ HOT 2
- Custom Validators are not working after updating to Angular 11 HOT 8
- Not working when upgrading to Angular 12 HOT 4
- NGX-CUSTOM-VALIDATOR **NOT WORK** After Upgrade Angular Version HOT 2
- Incompatibility with Angular 13 HOT 5
- Add the License File
- Angular 16- ngx-custom-validators is not compatible with Angular Ivy HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ngx-custom-validators.