{"id":41032,"date":"2024-11-06T02:46:20","date_gmt":"2024-11-06T02:46:20","guid":{"rendered":"https:\/\/atmokpo.com\/w\/?p=41032"},"modified":"2024-11-26T06:37:46","modified_gmt":"2024-11-26T06:37:46","slug":"8-next-js%ec%97%90%ec%84%9c-%eb%8f%99%ec%a0%81-%eb%9d%bc%ec%9a%b0%ed%8c%85-%eb%b0%8f-%ed%8e%98%ec%9d%b4%ec%a7%80-%ec%83%9d%ec%84%b1%ed%95%98%ea%b8%b0-getstaticpaths%ec%99%80-getstaticprops%eb%a5%bc","status":"publish","type":"post","link":"https:\/\/atmokpo.com\/w\/41032\/","title":{"rendered":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305"},"content":{"rendered":"<p>Next.js\ub294 React \uae30\ubc18\uc758 \ud504\ub808\uc784\uc6cc\ud06c\ub85c\uc11c, \uc11c\ubc84 \uc0ac\uc774\ub4dc \ub80c\ub354\ub9c1(SSR)\uacfc \uc815\uc801 \uc0ac\uc774\ud2b8 \uc0dd\uc131(SSG)\uc744 \uc27d\uac8c \uad6c\ud604\ud560 \uc218 \uc788\ub3c4\ub85d \ub3c4\uc640\uc90d\ub2c8\ub2e4. \uc774 \uae00\uc5d0\uc11c\ub294 Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131 \uae30\ub2a5\uc5d0 \ub300\ud574 \uc790\uc138\ud788 \uc124\uba85\ud558\uace0, <code>getStaticPaths<\/code>\uc640 <code>getStaticProps<\/code>\uc758 \uc0ac\uc6a9\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uaca0\uc2b5\ub2c8\ub2e4.<\/p>\n<h2>1. \ub3d9\uc801 \ub77c\uc6b0\ud305\uc774\ub780?<\/h2>\n<p>\ub3d9\uc801 \ub77c\uc6b0\ud305\uc740 URL \uacbd\ub85c\uc758 \uc77c\ubd80\uac00 \ub3d9\uc801\uc73c\ub85c \uc0dd\uc131\ub418\uac70\ub098 \ubcc0\ud654\ud558\ub294 \ub77c\uc6b0\ud305 \ubc29\uc2dd\uc744 \uc758\ubbf8\ud569\ub2c8\ub2e4. \uc608\ub97c \ub4e4\uc5b4, \ube14\ub85c\uadf8 \uac8c\uc2dc\ubb3c\uc758 URL\uc774 <code>\/posts\/[id]<\/code>\uc640 \uac19\uc774 \ud2b9\uc815 ID\uc5d0 \ub530\ub77c \ubcc0\uacbd\ub420 \uacbd\uc6b0, \uc774\ub97c \ub3d9\uc801 \ub77c\uc6b0\ud305\uc774\ub77c\uace0 \ud569\ub2c8\ub2e4. Next.js\uc5d0\uc11c\ub294 \ud30c\uc77c \uc2dc\uc2a4\ud15c \uae30\ubc18\uc758 \ub77c\uc6b0\ud305 \uc2dc\uc2a4\ud15c\uc744 \uc0ac\uc6a9\ud558\uc5ec \ub3d9\uc801 \ub77c\uc6b0\ud305\uc744 \ub9e4\uc6b0 \uac04\ud3b8\ud558\uac8c \uad6c\ud604\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<h2>2. Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305 \uad6c\ud604\ud558\uae30<\/h2>\n<p>Next.js\uc5d0\uc11c\ub294 \ub3d9\uc801 \ub77c\uc6b0\ud2b8\ub97c \ub9cc\ub4e4\uae30 \uc704\ud574 \ub300\uad04\ud638(<code>[]<\/code>)\ub97c \uc0ac\uc6a9\ud558\uc5ec \ud30c\uc77c \ubc0f \ud3f4\ub354 \uc774\ub984\uc744 \uc9c0\uc815\ud569\ub2c8\ub2e4. \uc608\ub97c \ub4e4\uc5b4, <code>pages\/posts\/[id].js<\/code>\ub77c\ub294 \ud30c\uc77c\uc744 \uc0dd\uc131\ud558\uba74, <code>\/posts\/1<\/code>, <code>\/posts\/2<\/code>\uc640 \uac19\uc740 URL\uc744 \ucc98\ub9ac\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<pre><code> \n\/\/ pages\/posts\/[id].js\n\nimport { useRouter } from 'next\/router';\n\nconst Post = () =&gt; {\n    const router = useRouter();\n    const { id } = router.query;\n\n    return (\n        <div>\n            <h1>Post ID: {id}<\/h1>\n        <\/div>\n    );\n};\n\nexport default Post;\n<\/code><\/pre>\n<p>\uc704 \ucf54\ub4dc\ub294 \ub3d9\uc801 URL\uc5d0\uc11c \uac00\uc838\uc628 ID\ub97c \ud654\uba74\uc5d0 \ud45c\uc2dc\ud558\ub294 \uac04\ub2e8\ud55c \ucef4\ud3ec\ub10c\ud2b8\uc785\ub2c8\ub2e4. \uadf8\ub7ec\ub098 \uc2e4\uc81c \uc560\ud50c\ub9ac\ucf00\uc774\uc158\uc5d0\uc11c\ub294 \ub370\uc774\ud130 fetching\uc774 \ud544\uc694\ud569\ub2c8\ub2e4. \uc774\ub97c \uc704\ud574 <code>getStaticPaths<\/code>\uc640 <code>getStaticProps<\/code>\ub97c \uc0ac\uc6a9\ud558\uac8c \ub429\ub2c8\ub2e4.<\/p>\n<h2>3. getStaticPaths\uc640 getStaticProps \uc18c\uac1c<\/h2>\n<p><code>getStaticPaths<\/code>\ub294 Next.js\uc5d0\uac8c \uc5b4\ub5a4 \uacbd\ub85c\ub97c \ubbf8\ub9ac \uc0dd\uc131\ud574\uc57c \ud558\ub294\uc9c0 \uc54c\ub824\uc8fc\ub294 \ud568\uc218\uc785\ub2c8\ub2e4. \uc774 \ud568\uc218\ub294 \ub3d9\uc801 \ub77c\uc6b0\ud305\uc744 \uc0ac\uc6a9\ud560 \ub54c \ubbf8\ub9ac \ub80c\ub354\ub9c1\ud560 \uacbd\ub85c\uc758 \ubaa9\ub85d\uc744 \uc81c\uacf5\ud558\ub294 \uc5ed\ud560\uc744 \ud569\ub2c8\ub2e4. \ubc18\uba74\uc5d0 <code>getStaticProps<\/code>\ub294 \ud2b9\uc815 \ud398\uc774\uc9c0\ub97c \ubbf8\ub9ac \uc0dd\uc131\ud560 \ub54c \ud544\uc694\ud55c \ub370\uc774\ud130\ub97c \uac00\uc838\uc624\ub294 \ub370 \uc0ac\uc6a9\ub429\ub2c8\ub2e4.<\/p>\n<h2>4. getStaticPaths \uc0ac\uc6a9\ud558\uae30<\/h2>\n<p>\uc6b0\uc120 <code>getStaticPaths<\/code>\ub97c \uc0ac\uc6a9\ud558\uc5ec \ubbf8\ub9ac \uc0dd\uc131\ud560 \uacbd\ub85c\ub97c \uc815\uc758\ud574\ubcf4\uaca0\uc2b5\ub2c8\ub2e4. \ub2e4\uc74c\uc740 \uc608\uc2dc \ucf54\ub4dc\uc785\ub2c8\ub2e4.<\/p>\n<pre><code> \n\/\/ pages\/posts\/[id].js\n\nexport async function getStaticPaths() {\n    \/\/ \uc608\uc2dc \ub370\uc774\ud130\ub97c \ubc30\uc5f4\ub85c \uc815\uc758\n    const posts = [\n        { id: '1' },\n        { id: '2' },\n        { id: '3' }\n    ];\n\n    \/\/ paths \ubc30\uc5f4 \ud615\ud0dc\ub85c \uacbd\ub85c \uc815\uc758\n    const paths = posts.map(post =&gt; ({\n        params: { id: post.id }\n    }));\n\n    return { paths, fallback: false };\n}\n<\/code><\/pre>\n<p>\uc704 \ucf54\ub4dc\uc5d0\uc11c <code>getStaticPaths<\/code>\ub294 ID\uac00 1, 2, 3\uc778 \uac8c\uc2dc\ubb3c \uacbd\ub85c\ub97c \uc815\uc758\ud588\uc2b5\ub2c8\ub2e4. <code>fallback: false<\/code> \uc124\uc815\uc740 \uc815\uc758\ub41c \uacbd\ub85c \uc678\uc758 \uc694\uccad\uc774 \ub4e4\uc5b4\uc624\uba74 404 \ud398\uc774\uc9c0\ub97c \ubc18\ud658\ud558\uac8c \ud569\ub2c8\ub2e4.<\/p>\n<h2>5. getStaticProps \uc0ac\uc6a9\ud558\uae30<\/h2>\n<p>\uadf8\ub7f0 \ub2e4\uc74c, <code>getStaticProps<\/code>\ub97c \uc0ac\uc6a9\ud558\uc5ec \uac01 \uac8c\uc2dc\ubb3c\uc5d0 \ub300\ud55c \ub370\uc774\ud130\ub97c \uac00\uc838\uc624\uaca0\uc2b5\ub2c8\ub2e4. \uc544\ub798\ub294 \uc774\uc5d0 \ub300\ud55c \ucf54\ub4dc\uc785\ub2c8\ub2e4.<\/p>\n<pre><code> \n\/\/ pages\/posts\/[id].js\n\nexport async function getStaticProps({ params }) {\n    const { id } = params;\n\n    \/\/ \uc5ec\uae30\uc5d0 \uc2e4\uc81c \ub370\uc774\ud130 fetching \ub85c\uc9c1\uc744 \ub123\uc744 \uc218 \uc788\uc2b5\ub2c8\ub2e4.\n    const posts = [\n        { id: '1', title: '\uccab \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 1' },\n        { id: '2', title: '\ub450 \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 2' },\n        { id: '3', title: '\uc138 \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 3' }\n    ];\n    \n    const post = posts.find(post =&gt; post.id === id);\n\n    return {\n        props: {\n            post\n        },\n    };\n}\n<\/code><\/pre>\n<p>\uc704 \ucf54\ub4dc\uc5d0\uc11c\ub294 \uac8c\uc2dc\ubb3c ID\uc5d0 \ud574\ub2f9\ud558\ub294 \uac8c\uc2dc\ubb3c\uc744 \ucc3e\uc544\uc11c \uadf8 \ub370\uc774\ud130\ub97c <code>props<\/code>\ub85c \ubc18\ud658\ud569\ub2c8\ub2e4. \uc774\uc81c \uac8c\uc2dc\ubb3c \ub0b4\uc6a9\uc744 \ucd9c\ub825\ud560 \uc218 \uc788\ub3c4\ub85d \ucef4\ud3ec\ub10c\ud2b8\ub97c \uc218\uc815\ud558\uaca0\uc2b5\ub2c8\ub2e4.<\/p>\n<pre><code> \n\/\/ pages\/posts\/[id].js\n\nconst Post = ({ post }) =&gt; {\n    return (\n        <div>\n            <h1>{post.title}<\/h1>\n            <p>{post.content}<\/p>\n        <\/div>\n    );\n};\n\nexport default Post;\n<\/code><\/pre>\n<h2>6. \uc804\uccb4 \ucf54\ub4dc<\/h2>\n<p>\uc704\uc758 \ubaa8\ub4e0 \ub0b4\uc6a9\uc744 \ud1b5\ud569\ud558\uba74 \ucd5c\uc885 \ucf54\ub4dc\ub294 \ub2e4\uc74c\uacfc \uac19\uc2b5\ub2c8\ub2e4.<\/p>\n<pre><code> \n\/\/ pages\/posts\/[id].js\n\nimport { useRouter } from 'next\/router';\n\nexport async function getStaticPaths() {\n    const posts = [\n        { id: '1' },\n        { id: '2' },\n        { id: '3' }\n    ];\n\n    const paths = posts.map(post =&gt; ({\n        params: { id: post.id }\n    }));\n\n    return { paths, fallback: false };\n}\n\nexport async function getStaticProps({ params }) {\n    const { id } = params;\n\n    const posts = [\n        { id: '1', title: '\uccab \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 1' },\n        { id: '2', title: '\ub450 \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 2' },\n        { id: '3', title: '\uc138 \ubc88\uc9f8 \uac8c\uc2dc\ubb3c', content: '\ub0b4\uc6a9 3' }\n    ];\n    \n    const post = posts.find(post =&gt; post.id === id);\n\n    return {\n        props: {\n            post\n        },\n    };\n}\n\nconst Post = ({ post }) =&gt; {\n    return (\n        <div>\n            <h1>{post.title}<\/h1>\n            <p>{post.content}<\/p>\n        <\/div>\n    );\n};\n\nexport default Post;\n<\/code><\/pre>\n<h2>7. \uacb0\ub860<\/h2>\n<p>\uc774\ubc88 \uae00\uc5d0\uc11c\ub294 Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305\uc744 \uad6c\ud604\ud558\ub294 \ubc29\ubc95\uacfc <code>getStaticPaths<\/code> \ubc0f <code>getStaticProps<\/code>\uc758 \uc0ac\uc6a9\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uc558\uc2b5\ub2c8\ub2e4. \uc774\ub7ec\ud55c \uae30\ub2a5\uc744 \ud65c\uc6a9\ud558\uba74 \ubbf8\ub9ac \uc815\uc758\ub41c \uacbd\ub85c\uc5d0 \ub300\ud574 \uc815\uc801 \ud398\uc774\uc9c0\ub97c \uc0dd\uc131\ud558\uace0, \uac01 \ud398\uc774\uc9c0\uc5d0 \ud544\uc694\ud55c \ub370\uc774\ud130\ub97c \ud6a8\uacfc\uc801\uc73c\ub85c \uac00\uc838\uc62c \uc218 \uc788\uc2b5\ub2c8\ub2e4. \uc774\ub97c \ud1b5\ud574 \uc131\ub2a5\uacfc SEO \ucd5c\uc801\ud654\ub97c \uc774\ub8f0 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<p>Next.js\ub294 \uac15\ub825\ud55c \uae30\ub2a5\uc744 \uc81c\uacf5\ud558\uc5ec, \ub300\uaddc\ubaa8 \uc560\ud50c\ub9ac\ucf00\uc774\uc158\uc758 \uac1c\ubc1c\uc744 \ub354\uc6b1 \uac04\ud3b8\ud558\uac8c \ub9cc\ub4e4\uc5b4 \uc90d\ub2c8\ub2e4. \ubcf8 \ubb38\uc11c\ub97c \ud1b5\ud574 Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305\uacfc \ud398\uc774\uc9c0 \uc0dd\uc131\uc744 \uc704\ud55c \uccab \ubc1c\uc744 \ub0b4\ub51b\ub294 \ub370 \ub3c4\uc6c0\uc774 \ub418\uc5c8\uae30\ub97c \ubc14\ub78d\ub2c8\ub2e4. \uc55e\uc73c\ub85c\ub3c4 \ub354\uc6b1 \ub2e4\uc591\ud55c Next.js\uc758 \uae30\ub2a5\uc744 \ud65c\uc6a9\ud574 \ubcf4\uc2dc\uae38 \ucd94\ucc9c\ub4dc\ub9bd\ub2c8\ub2e4.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Next.js\ub294 React \uae30\ubc18\uc758 \ud504\ub808\uc784\uc6cc\ud06c\ub85c\uc11c, \uc11c\ubc84 \uc0ac\uc774\ub4dc \ub80c\ub354\ub9c1(SSR)\uacfc \uc815\uc801 \uc0ac\uc774\ud2b8 \uc0dd\uc131(SSG)\uc744 \uc27d\uac8c \uad6c\ud604\ud560 \uc218 \uc788\ub3c4\ub85d \ub3c4\uc640\uc90d\ub2c8\ub2e4. \uc774 \uae00\uc5d0\uc11c\ub294 Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131 \uae30\ub2a5\uc5d0 \ub300\ud574 \uc790\uc138\ud788 \uc124\uba85\ud558\uace0, getStaticPaths\uc640 getStaticProps\uc758 \uc0ac\uc6a9\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. \ub3d9\uc801 \ub77c\uc6b0\ud305\uc774\ub780? \ub3d9\uc801 \ub77c\uc6b0\ud305\uc740 URL \uacbd\ub85c\uc758 \uc77c\ubd80\uac00 \ub3d9\uc801\uc73c\ub85c \uc0dd\uc131\ub418\uac70\ub098 \ubcc0\ud654\ud558\ub294 \ub77c\uc6b0\ud305 \ubc29\uc2dd\uc744 \uc758\ubbf8\ud569\ub2c8\ub2e4. \uc608\ub97c \ub4e4\uc5b4, \ube14\ub85c\uadf8 \uac8c\uc2dc\ubb3c\uc758 URL\uc774 \/posts\/[id]\uc640 \uac19\uc774 \ud2b9\uc815 ID\uc5d0 &hellip; <a href=\"https:\/\/atmokpo.com\/w\/41032\/\" class=\"more-link\">\ub354 \ubcf4\uae30<span class=\"screen-reader-text\"> &#8220;8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[223],"tags":[],"class_list":["post-41032","post","type-post","status-publish","format-standard","hentry","category-nextjs"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/atmokpo.com\/w\/41032\/\" \/>\n<meta property=\"og:locale\" content=\"ko_KR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"og:description\" content=\"Next.js\ub294 React \uae30\ubc18\uc758 \ud504\ub808\uc784\uc6cc\ud06c\ub85c\uc11c, \uc11c\ubc84 \uc0ac\uc774\ub4dc \ub80c\ub354\ub9c1(SSR)\uacfc \uc815\uc801 \uc0ac\uc774\ud2b8 \uc0dd\uc131(SSG)\uc744 \uc27d\uac8c \uad6c\ud604\ud560 \uc218 \uc788\ub3c4\ub85d \ub3c4\uc640\uc90d\ub2c8\ub2e4. \uc774 \uae00\uc5d0\uc11c\ub294 Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131 \uae30\ub2a5\uc5d0 \ub300\ud574 \uc790\uc138\ud788 \uc124\uba85\ud558\uace0, getStaticPaths\uc640 getStaticProps\uc758 \uc0ac\uc6a9\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. \ub3d9\uc801 \ub77c\uc6b0\ud305\uc774\ub780? \ub3d9\uc801 \ub77c\uc6b0\ud305\uc740 URL \uacbd\ub85c\uc758 \uc77c\ubd80\uac00 \ub3d9\uc801\uc73c\ub85c \uc0dd\uc131\ub418\uac70\ub098 \ubcc0\ud654\ud558\ub294 \ub77c\uc6b0\ud305 \ubc29\uc2dd\uc744 \uc758\ubbf8\ud569\ub2c8\ub2e4. \uc608\ub97c \ub4e4\uc5b4, \ube14\ub85c\uadf8 \uac8c\uc2dc\ubb3c\uc758 URL\uc774 \/posts\/[id]\uc640 \uac19\uc774 \ud2b9\uc815 ID\uc5d0 &hellip; \ub354 \ubcf4\uae30 &quot;8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/atmokpo.com\/w\/41032\/\" \/>\n<meta property=\"og:site_name\" content=\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"article:published_time\" content=\"2024-11-06T02:46:20+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-11-26T06:37:46+00:00\" \/>\n<meta name=\"author\" content=\"root\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:site\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:label1\" content=\"\uae00\uc4f4\uc774\" \/>\n\t<meta name=\"twitter:data1\" content=\"root\" \/>\n\t<meta name=\"twitter:label2\" content=\"\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04\" \/>\n\t<meta name=\"twitter:data2\" content=\"1\ubd84\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/\"},\"author\":{\"name\":\"root\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\"},\"headline\":\"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305\",\"datePublished\":\"2024-11-06T02:46:20+00:00\",\"dateModified\":\"2024-11-26T06:37:46+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/\"},\"wordCount\":41,\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"articleSection\":[\"nextjs\"],\"inLanguage\":\"ko-KR\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/\",\"url\":\"https:\/\/atmokpo.com\/w\/41032\/\",\"name\":\"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#website\"},\"datePublished\":\"2024-11-06T02:46:20+00:00\",\"dateModified\":\"2024-11-26T06:37:46+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/#breadcrumb\"},\"inLanguage\":\"ko-KR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/atmokpo.com\/w\/41032\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/atmokpo.com\/w\/41032\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\ud648\",\"item\":\"https:\/\/atmokpo.com\/w\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/atmokpo.com\/w\/#website\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/atmokpo.com\/w\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ko-KR\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"contentUrl\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"width\":400,\"height\":400,\"caption\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\"},\"image\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/x.com\/bebubo4\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\",\"name\":\"root\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"caption\":\"root\"},\"sameAs\":[\"http:\/\/atmokpo.com\/w\"],\"url\":\"https:\/\/atmokpo.com\/w\/author\/root\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/atmokpo.com\/w\/41032\/","og_locale":"ko_KR","og_type":"article","og_title":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","og_description":"Next.js\ub294 React \uae30\ubc18\uc758 \ud504\ub808\uc784\uc6cc\ud06c\ub85c\uc11c, \uc11c\ubc84 \uc0ac\uc774\ub4dc \ub80c\ub354\ub9c1(SSR)\uacfc \uc815\uc801 \uc0ac\uc774\ud2b8 \uc0dd\uc131(SSG)\uc744 \uc27d\uac8c \uad6c\ud604\ud560 \uc218 \uc788\ub3c4\ub85d \ub3c4\uc640\uc90d\ub2c8\ub2e4. \uc774 \uae00\uc5d0\uc11c\ub294 Next.js\uc758 \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131 \uae30\ub2a5\uc5d0 \ub300\ud574 \uc790\uc138\ud788 \uc124\uba85\ud558\uace0, getStaticPaths\uc640 getStaticProps\uc758 \uc0ac\uc6a9\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. \ub3d9\uc801 \ub77c\uc6b0\ud305\uc774\ub780? \ub3d9\uc801 \ub77c\uc6b0\ud305\uc740 URL \uacbd\ub85c\uc758 \uc77c\ubd80\uac00 \ub3d9\uc801\uc73c\ub85c \uc0dd\uc131\ub418\uac70\ub098 \ubcc0\ud654\ud558\ub294 \ub77c\uc6b0\ud305 \ubc29\uc2dd\uc744 \uc758\ubbf8\ud569\ub2c8\ub2e4. \uc608\ub97c \ub4e4\uc5b4, \ube14\ub85c\uadf8 \uac8c\uc2dc\ubb3c\uc758 URL\uc774 \/posts\/[id]\uc640 \uac19\uc774 \ud2b9\uc815 ID\uc5d0 &hellip; \ub354 \ubcf4\uae30 \"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305\"","og_url":"https:\/\/atmokpo.com\/w\/41032\/","og_site_name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","article_published_time":"2024-11-06T02:46:20+00:00","article_modified_time":"2024-11-26T06:37:46+00:00","author":"root","twitter_card":"summary_large_image","twitter_creator":"@bebubo4","twitter_site":"@bebubo4","twitter_misc":{"\uae00\uc4f4\uc774":"root","\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04":"1\ubd84"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/atmokpo.com\/w\/41032\/#article","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/41032\/"},"author":{"name":"root","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7"},"headline":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305","datePublished":"2024-11-06T02:46:20+00:00","dateModified":"2024-11-26T06:37:46+00:00","mainEntityOfPage":{"@id":"https:\/\/atmokpo.com\/w\/41032\/"},"wordCount":41,"publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"articleSection":["nextjs"],"inLanguage":"ko-KR"},{"@type":"WebPage","@id":"https:\/\/atmokpo.com\/w\/41032\/","url":"https:\/\/atmokpo.com\/w\/41032\/","name":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/#website"},"datePublished":"2024-11-06T02:46:20+00:00","dateModified":"2024-11-26T06:37:46+00:00","breadcrumb":{"@id":"https:\/\/atmokpo.com\/w\/41032\/#breadcrumb"},"inLanguage":"ko-KR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/atmokpo.com\/w\/41032\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/atmokpo.com\/w\/41032\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\ud648","item":"https:\/\/atmokpo.com\/w\/en\/"},{"@type":"ListItem","position":2,"name":"8.Next.js\uc5d0\uc11c \ub3d9\uc801 \ub77c\uc6b0\ud305 \ubc0f \ud398\uc774\uc9c0 \uc0dd\uc131\ud558\uae30, getStaticPaths\uc640 getStaticProps\ub97c \ud65c\uc6a9\ud55c \ub3d9\uc801 \ub77c\uc6b0\ud305"}]},{"@type":"WebSite","@id":"https:\/\/atmokpo.com\/w\/#website","url":"https:\/\/atmokpo.com\/w\/","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","description":"","publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/atmokpo.com\/w\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ko-KR"},{"@type":"Organization","@id":"https:\/\/atmokpo.com\/w\/#organization","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","url":"https:\/\/atmokpo.com\/w\/","logo":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/","url":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","contentUrl":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","width":400,"height":400,"caption":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8"},"image":{"@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/bebubo4"]},{"@type":"Person","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7","name":"root","image":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","caption":"root"},"sameAs":["http:\/\/atmokpo.com\/w"],"url":"https:\/\/atmokpo.com\/w\/author\/root\/"}]}},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/41032","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/comments?post=41032"}],"version-history":[{"count":1,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/41032\/revisions"}],"predecessor-version":[{"id":41033,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/41032\/revisions\/41033"}],"wp:attachment":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/media?parent=41032"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/categories?post=41032"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/tags?post=41032"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}