tuplejump / play-yeoman

Play + Yeoman integration sbt and play plugins
Apache License 2.0
237 stars 58 forks source link

Route configurations for angular html5mode #19

Closed ioRekz closed 10 years ago

ioRekz commented 11 years ago

Any advice/idea in order to run angular with html5mode set to true ?

milliondreams commented 10 years ago

There shouldn't be any issue with that? Did you try it? Is there an issue?

milliondreams commented 10 years ago

Updated yo-demo on AngularHTML5Mode branch to demo this working.

Changes required -

  1. Add to head in index.html
  2. Prefix ui/ to all javascript and stylesheet src/href attributes
  3. Update Angular App config to use ui/ instead of / as the base URL
  4. Change the href links to point to ui/route instead of just route

See this commit for details - https://github.com/tuplejump/play-yeoman/commit/d6f7bfc3b0532ba2e10d9bcc67023810e42d5987

jtammen commented 10 years ago

I just played around a little bit with this as I want to enable HTML5 mode, as well. The problem is that deep linking into the Angular app does not work because of the routing. So this only works if the user navigates to the app entry point at first.

Is anyone using play-yeoman successfully with HTML5 mode enabled?