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

376
Views
Al agregar 'ngRoute' en mi módulo, envía una URL diferente

Tengo npm instalado correctamente ngRoute con su versión y agregado en mi archivo index.html.

El problema aquí es que agrega los parámetros #! al final de mi URL localhost así:

 http://127.0.0.1:5500/#!/

En lugar de tener algo como esto:

 http://127.0.0.1:5500

Agregué el ngRoute en mi módulo así:

 angular.module('todoApp', ['ngRoute']) .config(['$routeProvider', function($routeProvider) { $routeProvider .when("/", { templateUrl: 'views/home.html', //controller: 'homeController' })

Tan pronto como agregué este código en mi archivo app.js que controla el front-end con Angularjs, toda mi aplicación colapsa debido al hecho de que mi URL cambia por completo.

De hecho, en mi index.html tengo que agregar para ir a mi página de inicio lo siguiente:

 <a href="#!/"

De lo contrario, no enviará el enrutador URL correcto para ngRoute.

No sé que más hacer.

about 4 years ago · Juan Pablo Isaza
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!