Skip to content
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

In tutorial, add fragments around multiple elements #133

Merged
merged 1 commit into from
Jan 21, 2025
Merged
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
36 changes: 23 additions & 13 deletions docs/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,10 @@ Click the tabs below to see the contents:
const {greet} = body

return (
<h1>{greet}</h1>
<span>{footer}</span>
<>
<h1>{greet}</h1>
<span>{footer}</span>
</>
)
}
```
Expand Down Expand Up @@ -331,9 +333,11 @@ props_template to skip over the block.
const {greet} = body

return (
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} data-sg-remote>Load Greet</a>
<span>{footer}</span>
<>
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} data-sg-remote>Load Greet</a>
<span>{footer}</span>
</>
)
}
```
Expand Down Expand Up @@ -376,9 +380,11 @@ add a link that will dig for the missing content to replace "Waiting for greet".
const { greet } = body

return (
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} data-sg-remote>Greet!</a>
<span>{footer}</span>
<>
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} data-sg-remote>Greet!</a>
<span>{footer}</span>
</>
)
}
```
Expand Down Expand Up @@ -406,9 +412,11 @@ export default function GreetShow() {
}

return (
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} onClick={handleClick}>Greet!</a>
<span>{footer}</span>
<>
<h1>{greet || "Waiting for greet"}</h1>
<a href={loadGreetPath} onClick={handleClick}>Greet!</a>
<span>{footer}</span>
</>
)
}
```
Expand Down Expand Up @@ -468,8 +476,10 @@ above without a button.
const { greet } = body

return (
<h1>{greet}</h1>
<span>{footer}</span>
<>
<h1>{greet}</h1>
<span>{footer}</span>
</>
)
}
```
Expand Down
Loading