Комментарии:
is TDD really necessary to use?
Ответитьhello sir i have a little problem about this,
Multiple form field elements in the same form have the same id attribute value. This might prevent the browser from correctly autofilling the form.
To fix this issue, use unique id attribute values for each form field.
its because if i click the password it goes up not like email if i click the input will stay
this is my input in password:
<ion-input name="password" formControlName="password" label-placement="floating" label="Password"
type="password" ></ion-input>
I've been stuck here its really awkward when i click the input password sir. :)
Thank you ;)
kurwa nie słychać cię
ОтветитьFor anyone who got error at file login.page.html, line "<app-error-message [field]= "form.get('email')" error="required" message="Email is mandatory"></app-error-message>", here is how to fix:
// change the field type
@Input() field!: AbstractControl<any, any> | null;
// also, update the if statement to
if (this.field?.touched && this.field.errors?.[this.error])
Even after changing the code for AbstractControl, I am getting the following error. Has someone experienced the same? How could you solve it? Thank you
I am still getting an error in the [field] in login.page.html . My error is: TS2322: Type ‘AbstractControl<any,any> | null’ is not assignable to type ‘AbstractControl<any,any>’. Type ‘null’ is not assignable to type ‘AbstractControl<any,any>’
I had the error Failed: Cannot read properties of undefined (reading 'touched')
I added check for undefined in error-message.component.ts
shouldShowComponent() {
//*ngIf="form.get('email').touched && form.get('email').errors?.['required']"
if (this.field === undefined)
return false;
if (this.field.touched && this.field.errors?.['required']) {
return true;
}
return false;
}
also i changed declaration to
@Input() field: AbstractControl;
Hello sir
I have been facing this problem for days
please help me, I'm working on my senior project :=(
ErrorMessageComponent > should hide error message on field touched, but no errors
Failed: Cannot read properties of undefined (reading 'touched')
YOU HELPED US ALOOOOOOOOOOOT WITH OUR SENIOR PROJECT TYSM!!!
ОтветитьI had a problem because I got "this.field is undefined" in the test, So I moved the
component.field = new FormGroup({email: new FormControl()});
inside the beforeEach
Thanks for the tutorial, really interesting the TDD stuff.
Hello,
I had this issue when writing:
<app-error-message [field]= "form.get('email')" error="required" message="Email is mandatory"></app-error-message>
The [field] part is giving me an error/warning, an under line red line, meaning something is not alright with my code, even if after following every step in the video for multiple times. However the app is running and functioning.
Error:
"Type 'AbstractControl' is missing the following properties from type 'FormGroup': controls, registerControl, addControl, removeControl"
After searching:
I found that from the file tsconfig.json.
Changing this part from "strictTemplates": true To "strictTemplates": false, did the trick.
I thought this might help someone. However not sure if this is ok on the long run.
Hi sir please help me. When Ever i try to run ""ionic cordova resources"" i get error of Cordova not installed in path, install Cordova globally.
I have installed Cordova already but i am still getting errors. Please help me i would really appreciate it.
Hello sir how to fatch data from firebase...
I want to fatch data with userId and CategoryId