Angular forms 2

Asked

Viewed 81 times

0

I have a screen called login on the same screen I have two Forms one with user and password and another only with email field. In the first form I have this snippet of code:

<a href="#" class=""> clique aqui

when I click: click here, I want to open second form on the same screen, ie, first form disappears and enters second form. How do ? already tried with jquery did not work. I am using angular 2.

  • 1

    Post your complete code so we can help you. Your question is very vague, give more details.

1 answer

0


Through the bridge

 <button (click)="form2 = !form2">Mudar</button>
      <input type="text" placeholder="email" *ngIf="form2">
      <input type="text" placeholder="form2 Email" *ngIf="!form2">

Or through the Hidden

  <button (click)="form2 = !form2">Mudar</button>
  <input type="text" placeholder="email" [hidden]="form2">
  <input type="text" placeholder="form2 Email" [hidden]="!form2">

Browser other questions tagged

You are not signed in. Login or sign up in order to post.