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

377
Views
When adding 'ngRoute' in my Module it send different URL

I have npm installed properly ngRoute with its version and added in my index.html file.

The problem here is that it adds the parameters #! at the end of my localhost URL like this:

http://127.0.0.1:5500/#!/

Instead of having something like this:

http://127.0.0.1:5500

I added the ngRoute in my module like this:

angular.module('todoApp', ['ngRoute'])

.config(['$routeProvider', function($routeProvider) {

$routeProvider

.when("/", {
  templateUrl: 'views/home.html',
  //controller: 'homeController'
})

As soon as I added this code in my app.js file that control the front-end with Angularjs my whole app collapses due to the fact that my URL changes completely.

In fact, in my index.html I have to add to go to my home page the next:

<a href="#!/"

Otherwise it won't send the right URL router for ngRoute.

I don't know what else to do.

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!