-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d2c19b9
commit f3a59a8
Showing
9 changed files
with
326 additions
and
140 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
packages/example-project/next-app/src/app/Button/Button.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
'use client'; | ||
|
||
import { useState } from 'react'; | ||
|
||
import { MyButton } from '../components'; | ||
|
||
function Button() { | ||
const [inputEvent, setInputEvent] = useState<number>(0); | ||
// return <MyButton>Hello</MyButton> | ||
return ( | ||
<> | ||
<MyButton | ||
suppressHydrationWarning | ||
onClick={(e) => { | ||
e.preventDefault(); | ||
e.stopPropagation() | ||
setInputEvent(inputEvent + 1) | ||
}} | ||
> | ||
Click me | ||
</MyButton> | ||
<div> | ||
<p>Input Event: {inputEvent}</p> | ||
</div> | ||
</> | ||
); | ||
} | ||
|
||
export default Button; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,10 @@ | ||
import Input from "./Input/Input"; | ||
import Button from "./Button/Button"; | ||
|
||
export default function Home() { | ||
return <Input />; | ||
return <> | ||
{/* <Input /> | ||
and */} | ||
<Button>Hello</Button> | ||
</>; | ||
} |
Oops, something went wrong.