Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

149
Views
Cadena de uso angular como nombre de salida

Necesito usar variable de cadena como outletname rr

este es mi código:

 public redirect(): any { let rr = 'productModal'; let rr2 = 'm/addProduct'; return this.router.navigate( ['link/link', {outlets: {rr: rr2}}] ); }
over 4 years ago · Santiago Trujillo
2 answers
Answer question

0

 public redirect(): any { let rr = 'productModal'; let rr2 = 'm/addProduct'; return this.router.navigate( ['link/link', {outlets: {[rr]: rr2}}] ); }
over 4 years ago · Santiago Trujillo Report

0

Si desea dar un nombre a la salida del enrutador y representar los componentes dentro de esa salida usando el nombre de la salida del enrutador, entonces la solución a continuación funciona.

Paso 1: asigne un nombre a la etiqueta de salida del enrutador usando el atributo de nombre, en su caso

 <router-outlet #outlet="outlet" name="rr"></router-outlet>

Paso 2: agregue el siguiente código a ese botón de redirección.

 [routerLink]="[{ outlets: {rr: ['m/addProduct']}} ]"

Paso 3: en el archivo app-routing.module.ts proporcione el nombre de salida, en su caso

 {path: 'm/addProduct', component: "Add product component", outlet: 'rr'}

La solución anterior funcionó para mí.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!