Skip to content

Add notices to client-side setup #373

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion resources/js/Pages/client-side-setup.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { A, Code, CodeBlock, H1, H2, P, TabbedCode } from '@/Components'
import { A, Code, CodeBlock, H1, H2, P, TabbedCode, Notice } from '@/Components'
import dedent from 'dedent-js'

export const meta = {
Expand Down Expand Up @@ -54,6 +54,9 @@ export default function () {
},
]}
/>
<Notice>
Remember to also install and configure the Vite plugin corresponding to your framework of choice.
</Notice>
<H2>Initialize the Inertia app</H2>
<P>
Next, update your main JavaScript file to boot your Inertia app. To accomplish this, we'll initialize the
Expand Down Expand Up @@ -140,6 +143,9 @@ export default function () {
The <Code>setup</Code> callback receives everything necessary to initialize the client-side framework, including
the root Inertia <Code>App</Code> component.
</P>
<Notice>
For React the entry file would need to be a <Code>.jsx</Code> or <Code>.tsx</Code> file, since JSX is used.
</Notice>
<H2>Resolving components</H2>
<P>
The <Code>resolve</Code> callback tells Inertia how to load a page component. It receives a page name (string),
Expand Down