CSS not loading after redirecting with RouterLink

I’m creating a link to the login page using RouterLink like this:

new RouterLink("ALREADY HAVE AN ACCOUNT?", LoginView.class)

I’m adding the stylesheets and doing an HTML import like this on the LoginView:

@Route(value = LoginView.ROUTE, layout = LoginLayout.class)
public class LoginView extends PolymerTemplate<LoginView.Model> implements AfterNavigationObserver {

When loading the page for the first time everything works fine. But when I use the redirect link from the register page using the RouterLink the CSS files imported are not loaded. It loads correctly if I refresh the page or if I use an Anchor link. I also tried adding the CSS files directly to the HTML template but I get the same behaviour.