Aurelia and Core Web Vitals

Hi,

It is known (and Google acknowledges it: https://web.dev/vitals-spa-faq/) that Core Web Vitals is unfair to SPAs.

At the same time, there are some really cool SPAs (like reddit) that mix both of the best: static urls using slash instead of hash and at the same time not reloading the website once the user open the first page.

Is vNext tackling any of these points?

  • Using slash (/) instead of hash (#) for the routing
  • Being to have the first page layout in the index.html instead of replacing the whole content of a div (avoid a big layout shift)

I’m curious to know if have it in mind when building vNext. I believe it could be a big differential towards the existing SPA engines.

Cheers

Using / instead of # has been supported since V1, you can enable push-state routing for that.
Router Configuration | Aurelia

your second point seems like a good fit for the .enhance() API, but it would require some work in the backend as well, because users can enter your app at any point. I’ve never had the need for this, so unfortunately I can’t help you further there

1 Like