Skip to content

Conversation

jasonvarga
Copy link
Member

@jasonvarga jasonvarga commented Sep 29, 2025

This PR converts the Control Panel to an Inertia app. ✨

Typically, requesting a non-Inertia page will load it in a modal to show you've got an error.
In our case, it'll just do a full reload instead. That way non-Inertia pages will continue to "just work".

go-dark-helmet-gif

Pages should feel much faster now. A bunch of the overhead that you'd get on every request now only needs to happen on the first request.

This PR is the initial wiring up to get to concept sorted out. Not every page has been converted to Inertia - non Inertia pages will trigger those full page reloads in the mean time. Additional PRs will come to bring over the rest of the pages.

booting callbacks need to be first because the component needs to be registered in order to get resolved by inertia.

components need to queued and then all actually registered later because they need be resolved by inertia before the vue app is started.
The View.vue was basically already the page component, but the props from the blade view are moved to the server.

This can obviously be cleaned up, but I converted it with as few changes as I could.
…tural line background shows via a server prop

remove globally registered component
# Conflicts:
#	src/Http/View/Composers/JavascriptComposer.php
Previously they were made available to the root vue app since they'd be used one-time from blade.

But now that there is always going to be a layout vue component, they are no longer at the top level.

Making them global for now, but they'll eventually get moved into their respective intertia page components.
…ever see a 404 outside since you'd get redirected to the login page
- fix additional breadcrumbs not appearing correctly
- clicking nav will immediately update nav, but the breadcrumbs only load when the request is done
- clicking breadcrumb will immediately update both.
- this gives the illusion of more instant requests without breadcrumbs popping in incorrectly
…king the nav. The 'active' logic is more complicated than matching a url. NavItem->isActive can probably be converted to js later.
# Conflicts:
#	resources/views/components/breadcrumbs/dropdown.blade.php
#	resources/views/components/breadcrumbs/index.blade.php
#	resources/views/components/docs-callout.blade.php
#	resources/views/components/view-site-button.blade.php
@jasonvarga jasonvarga marked this pull request as ready for review October 2, 2025 21:06
@jasonvarga jasonvarga merged commit 69d6190 into master Oct 2, 2025
18 checks passed
@jasonvarga jasonvarga deleted the inertia branch October 2, 2025 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant