์์ฝ css ๋ด๋ถ์ font asset์ ๋ฐ์์ค๋ path๋ฅผ ์ ๋๊ฒฝ๋ก๊ฐ ์๋ ์๋๊ฒฝ๋ก๋ก ๋ฐ๊พธ๋ฉด ๋๋ค. ๋ฌธ์ css์ url๋ก ์ ์ํด ๋ font asset์ด ๊ฐ๋ฐ๋ชจ๋(dev)์์๋ ์ ์ ์ฉ๋๋ค๊ฐ ์ค์๋ฒ(production)์์ ๋ฐ์๋์ง ์๋ ์ด์ ์ค์ ๊ตฌํ /* style.css */ @font-face { font-family: spoqaSansNeo; font-weight: 700; src:url('/font/SpoqaHanSansNeo-Bold.ttf'); src: url('/font/SpoqaHanSansNeo-Bold.otf') format("opentype"), url('/font/SpoqaHanSansNeo-Bold.ttf') format("truetype"); } /* next.config..
์ํฉ next.js์์๋ SSR์ ์ฌ์ฉํ๊ธฐ ๋๋ฌธ์ url์ ์๋ query๋ฅผ ๋ฐ์์ฌ ์๊ฐ ์๋ค. ํด๊ฒฐ 1 next page์์ getServerSideProps ํจ์๋ฅผ ์ด์ฉํด query๋ฅผ ๋ฐ์์ฌ ์ ์๋ค. const Page: NextPage = ({ params }) => { } export async function getServerSideProps (context) { const req = context.req; const params = new URLSearchParams(req._parsedUrl.query); return { props: { params } }; }โ ํด๊ฒฐ 2 ํด๊ฒฐ 1์ ๋ฐฉ๋ฒ์ผ๋ก page ๋ด๋ถ์์๋ url parameter๋ฅผ ์ฌ์ฉํ ์ ์๋ค. ํ์ง๋ง _app.tsx์ ๊ฐ์ด ne..
Comment