{"id":17042,"date":"2026-07-30T05:22:21","date_gmt":"2026-07-29T20:22:21","guid":{"rendered":"http:\/\/www.gisdeveloper.co.kr\/?p=17042"},"modified":"2026-07-30T05:26:54","modified_gmt":"2026-07-29T20:26:54","slug":"typescript-keyof-any","status":"publish","type":"post","link":"http:\/\/www.gisdeveloper.co.kr\/?p=17042","title":{"rendered":"TypeScript, <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof any<\/code> ?"},"content":{"rendered":"<p>\ud0c0\uc785\uc2a4\ud06c\ub9bd\ud2b8\ub85c \uc791\uc131\ub41c \ucf54\ub4dc\ub97c \ubcf4\uba74 keyof any\uac00 \ubb34\uc5c7\uc778\uac00&#8230; \ub77c\ub294 \uc758\ubb38\uc774 \uc0dd\uae41\ub2c8\ub2e4. \uacb0\ub860\ubd80\ud130 \uc774\uc57c\uae30\ud558\uba74 string | number | symbol \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc989, \uac1d\uccb4\ub97c \uad6c\uc131\ud558\ub294 \ud0a4\uac00 \uac00\uc9c8 \uc218 \uc788\ub294 \ud0c0\uc785\uc785\ub2c8\ub2e4. \ub2e4\uc74c \ucf54\ub4dc\ub97c \ubcf4\uaca0\uc2b5\ub2c8\ub2e4.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">\r\ntype Person = {\r\n    name: string;\r\n    age: number;\r\n};\r\n\r\ntype K = keyof Person;\r\n<\/pre>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">K<\/code>\ub294 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">\"name\" | \"age\"<\/code> \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc989, <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">Person<\/code> \uac1d\uccb4\uc758 key \uac12\uc73c\ub85c \uad6c\uc131\ub41c \uc720\ub2c8\uc5b8 \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc774\ub7ec\ud55c <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof<\/code>\uc758 \uc791\ub3d9\uc744 \ubd24\uc744\ub54c <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof any<\/code>\ub294 \uac1d\uccb4\uc758 key \uac12\uc73c\ub85c \uad6c\uc131\ub418\ub294 \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc989, \uc55e\uc11c \ubd24\ub358 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">string | number | symbol<\/code>\uc774 \ub429\ub2c8\ub2e4. <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">Person<\/code>\uc758 \uacbd\uc6b0 \ud0a4 \uac12\uc758 \ud0c0\uc785\uc740 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">string<\/code> \ubfd0\uc785\ub2c8\ub2e4. \ubc30\uc5f4\uc740 \ud0a4 \uac12\uc758 \ud0c0\uc785\uc73c\ub85c <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">number<\/code>\ub97c \uac16\uc2b5\ub2c8\ub2e4. \ud2b9\uc218\ud55c \uacbd\uc6b0 \ud0a4\uac12\uc758 \ud0c0\uc785\uc73c\ub85c <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">symbol<\/code>\uc744 \uac00\uc9c8 \uc218\ub3c4 \uc788\uad6c\uc694. \uadf8\ub798\uc11c \uac1d\uccb4\ub97c \uad6c\uc131\ud558\ub294 \ud0a4\uac00 \uac00\uc9c8 \uc218 \uc788\ub294 \ud0c0\uc785\uc740 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">string | number | symbol<\/code> \uc778 \uac83\uc785\ub2c8\ub2e4.<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof any<\/code>\uac00 \uac1d\uccb4\uc758 \ud0a4 \ud0c0\uc785\uc774\ub77c\ub294 \uac83\uc774\ub77c\ub294 \uac83\uc744 \uc989\uc2dc \uc720\ucd94\ud558\uae30\ub294 \uc77c\ubc18\uc801\uc73c\ub85c \uc5b4\ub835\uc2b5\ub2c8\ub2e4. \uadf8\ub798\uc11c TypeScript\ub294 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof any<\/code>\uc640 \ub3d9\uc77c\ud55c \ud0c0\uc785\uc73c\ub85c \ub2e4\uc74c\uacfc \uac19\uc740 <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">PropertyKey<\/code> \ud0c0\uc785\uc744 \ubbf8\ub9ac \uc815\uc758\ub450\uace0 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">\r\ntype PropertyKey = string | number | symbol;\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\ud0c0\uc785\uc2a4\ud06c\ub9bd\ud2b8\ub85c \uc791\uc131\ub41c \ucf54\ub4dc\ub97c \ubcf4\uba74 keyof any\uac00 \ubb34\uc5c7\uc778\uac00&#8230; \ub77c\ub294 \uc758\ubb38\uc774 \uc0dd\uae41\ub2c8\ub2e4. \uacb0\ub860\ubd80\ud130 \uc774\uc57c\uae30\ud558\uba74 string | number | symbol \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc989, \uac1d\uccb4\ub97c \uad6c\uc131\ud558\ub294 \ud0a4\uac00 \uac00\uc9c8 \uc218 \uc788\ub294 \ud0c0\uc785\uc785\ub2c8\ub2e4. \ub2e4\uc74c \ucf54\ub4dc\ub97c \ubcf4\uaca0\uc2b5\ub2c8\ub2e4. type Person = { name: string; age: number; }; type K = keyof Person; K\ub294 &#8220;name&#8221; | &#8220;age&#8221; \ud0c0\uc785\uc785\ub2c8\ub2e4. \uc989, Person \uac1d\uccb4\uc758 key \uac12\uc73c\ub85c \uad6c\uc131\ub41c \uc720\ub2c8\uc5b8 &hellip; <\/p>\n<p class=\"link-more\"><a href=\"http:\/\/www.gisdeveloper.co.kr\/?p=17042\" class=\"more-link\">\ub354 \ubcf4\uae30<span class=\"screen-reader-text\"> &#8220;TypeScript, <code class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\">keyof any<\/code> ?&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[157],"tags":[],"class_list":["post-17042","post","type-post","status-publish","format-standard","hentry","category-typescript"],"_links":{"self":[{"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/17042","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=17042"}],"version-history":[{"count":6,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/17042\/revisions"}],"predecessor-version":[{"id":17045,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/17042\/revisions\/17045"}],"wp:attachment":[{"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=17042"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=17042"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.gisdeveloper.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=17042"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}