Open sethharris4989 opened 5 years ago
Just came across this post by accident. I had the same problem/question. Lazy loading routes is probably not a good idea, because it delays the time until you first see posts. So I added a global variable (in another theme) with wp-localize script and translated them from php to vue-router. You could probably prepare all routes in PHP and use that to initialize your Router (in JS).
This may be outside of the scope of the project, but can you give any insights or advice on getting code splitting/lazy loading routes to this theme?
Bundle sizes can get out of control, so having this would put this theme over the top of anything else I've found.
Thanks!