add main
This commit is contained in:
26
src/app/components/ImgInputForm.client.tsx
Normal file
26
src/app/components/ImgInputForm.client.tsx
Normal file
@@ -0,0 +1,26 @@
|
||||
'use client'
|
||||
|
||||
import { useState } from "react"
|
||||
|
||||
const ImgInputForm_client = () => {
|
||||
|
||||
const [fileName, setFileName] = useState('')
|
||||
|
||||
const imgInput = () => {
|
||||
|
||||
|
||||
}
|
||||
|
||||
const confirm = () => {
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<>
|
||||
<input type="file" accept="image/*" onChange={imgInput} />
|
||||
<input type="button" value={'확인'} onClick={confirm}/>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
export default ImgInputForm_client
|
||||
9
src/app/components/ImgInputForm.server.tsx
Normal file
9
src/app/components/ImgInputForm.server.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
|
||||
import { cookies } from "next/headers"
|
||||
|
||||
const ImgInputForm_server = () => {
|
||||
console.log('cookies :: ' + cookies.name)
|
||||
return null
|
||||
}
|
||||
|
||||
export default ImgInputForm_server
|
||||
17
src/app/main/page.tsx
Normal file
17
src/app/main/page.tsx
Normal file
@@ -0,0 +1,17 @@
|
||||
|
||||
import ImgInputForm_client from '../components/ImgInputForm.client'
|
||||
import ImgInputForm_server from '../components/ImgInputForm.server'
|
||||
|
||||
const MainPage = () => {
|
||||
|
||||
return (
|
||||
<>
|
||||
<ImgInputForm_server />
|
||||
<ImgInputForm_client />
|
||||
</>
|
||||
|
||||
)
|
||||
|
||||
}
|
||||
|
||||
export default MainPage
|
||||
Reference in New Issue
Block a user