I’m building an AngularJS app with Rails 4 as an API and router. Using Rails for routing causes problems as users follow links, controller code on different pages isn’t being loaded. To solve this problem, I force page reloading by adding target=_self to links.

Haml example:

%a(href="/projects/{{project.id}}" target="_self") {{project.name}}

Comments