vendredi 11 décembre 2015

How to translate the url to the right route when the locationtype = history in emberjs?

I wrote a simple emberjs application,and set the router location type to 'history'

so i get some url from

http://localhost/#/post/1

to

http://localhost/post/1

the url changed by emberjs locally

however,when i refresh the page,i got an error

Cannot GET /post/1

seems nodejs cannot recognize that url

so,i wonder how to remap the absolute url to the route?

could you give me some hints?

thanks




Aucun commentaire:

Enregistrer un commentaire