🌐 US-Proxy
class="logged-out env-production page-responsive" style="word-wrap: break-word;" >
Skip to content

Facilitate admin customization - #2747

Merged
dunglas merged 1 commit into
api-platform:mainfrom
fzaninotto:easier-admin-customization
Aug 6, 2024
Merged

Facilitate admin customization#2747
dunglas merged 1 commit into
api-platform:mainfrom
fzaninotto:easier-admin-customization

Conversation

@fzaninotto

Copy link
Copy Markdown
Contributor

Closes #2745

Comment thread pwa/pages/admin/index.tsx
(async () => {
const HydraAdmin = (await import("@api-platform/admin")).HydraAdmin;
// load the admin client-side
const App = dynamic(() => import("../../components/admin/App"), {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the idiomatic way to lazy load a client-side component in next.js (and also the advised way to integrate react-admin and next.js, see https://marmelab.com/react-admin/NextJs.html)

@dunglas
dunglas merged commit 8fe4d52 into api-platform:main Aug 6, 2024
@dunglas

dunglas commented Aug 6, 2024

Copy link
Copy Markdown
Member

Thanks @fzaninotto!

back-2-95 pushed a commit to druidfi/api-platform that referenced this pull request Nov 27, 2024
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.

Make initial admin customization easier

2 participants