[Solved] Submit form as POST request and open new tab/window in Angular


Import the ReactiveFormsModule in your App.module.ts file

Update:

try it this way:

<form #form method="post" target="_blank" action="https://www.google.com/">
  <input type="hidden" value="auth-token" />
  <button mat-button color="primary" type="submit" (click)="form.submit()">Submit</button>
  <input type="submit" value="Submit" />
</form>

2

solved Submit form as POST request and open new tab/window in Angular