chris
chris

Reputation: 2607

How to disable routing in angularjs?

I have a single page application that really just has one single page. There's just the one view that has lots of javascript/ajax logic done with angularjs, but there's no routing to other views involved.

Therefore I'd like to git rid of the hashbang (#/) at the end of the url. Can I somehow turn off angularjs routing completely?

Btw: I know about Htm5Mode, but I want it to work in all browsers.

Upvotes: 9

Views: 5279

Answers (1)

John Woodruff
John Woodruff

Reputation: 1666

If you don't have a $routeProvider defined, there will be no routing, and therefore no hash in your url.

Upvotes: 2

Related Questions