<select onchange=\"onChange(this)\">\r\n <option value=\"1\">\uc11c\uc6b8<\/option>\r\n <option value=\"2\">\uacbd\uae30\ub3c4<\/option>\r\n <option value=\"3\">\uc778\ucc9c<\/option>\r\n<\/select><\/code><\/pre>\n\n\n\n\uc704\uc5d0 \uc120\ud0dd\ub41c \uac12\uc5d0 \ub530\ub77c\uc11c \ud638\ucd9c\ud574\uc57c\ud558\ub294 \ud568\uc218\uac00 \ub2e4\ub974\ub2e4.<\/p>\n\n\n\n
\uc11c\uc6b8 \uc120\ud0dd \uc2dc Seoul()
\uacbd\uae30 \uc120\ud0dd \uc2dc Gyeonggi()
\uc778\ucc9c \uc120\ud0dd \uc2dc Incheon()<\/p>\n\n\n\n
\uc774\ub807\uac8c \ub9d0\uc774\ub2e4. \uadf8\ub7ec\uba74 onChange \uc774\ubca4\ud2b8\ub97c \ud0dc\uc6cc \uac01\uac01 value \uac12\uc5d0 \ub530\ub77c\uc11c \ud568\uc218\ub97c \ub2e4 \ub2e4\ub974\uac8c \ud560 \uac83\uc778\uac00? <\/p>\n\n\n\n
\uc774\ub807\uac8c?<\/p>\n\n\n\n
const onChange = (target) => {\r\n const value = target.value\r\n\r\n if(value === 1) {\r\n seoul();\r\n } else if(value === 2) {\r\n gyeonggi()\r\n } else if(value === 3) {\r\n incheon()\r\n } ...\r\n}<\/code><\/pre>\n\n\n\n\ubb3c\ub860, \uac12\uc774 3\uac1c\uc77c \uacbd\uc6b0\uc5d0\ub294 \uc704\uac00 \uac00\ub3c5\uc131\uc774 \ub354 \uc88b\uc744 \uc218 \uc788\ub2e4. \ud558\uc9c0\ub9cc, \ub098\ub294 \uc5ec\uae30\uc11c \uac01 option\uc5d0 \uc18d\uc131\uac12\uc744 \uc8fc\uace0 \uadf8 \ud14d\uc2a4\ud2b8\ub85c \uac01\uac01\uc758 \ud568\uc218\ub97c \ud638\ucd9c\ud558\uac8c \ud558\uc600\ub2e4.<\/p>\n\n\n\n
const onChange = (target) => {\n target.value() \/\/ \ud568\uc218 \ud638\ucd9c! \uc774\ub807\uac8c \ud558\uba74 \uc548\ub41c\ub2e4 ! \uc774\uac74 \ud558\ub098\uc758 \uc608\uc2dc\uc77c\ubfd0, \n}<\/code><\/pre>\n\n\n\n\uac01\uac01\uc758 \ud568\uc218\ub97c \ud638\ucd9c\ud558\uac8c\ub054 \ud558\uba74 \uc800\ub807\uac8c \ud55c\uc904\ub9cc\uc73c\ub85c \ub05d\uc774 \ub09c\ub2e4. \ud83d\ude00<\/p>\n\n\n\n
<\/p>\n\n\n\n
\n\n\n\n\uadf8\ub7fc \uc774\uc81c \ub9cc\ub4e4\uc5b4\ubcf4\uc790!<\/p>\n\n\n\n
<\/span>\ud568\uc218 \ub9cc\ub4e4\uae30<\/span><\/h2>\n\n\n\n\uc784\uc2dc\ub85c \ud14c\uc2a4\ud2b8\ud560 \ud568\uc218\ub97c \ub9cc\ub4e0\ub2e4.<\/p>\n\n\n\n
function test() { \n console.log('test');\n}\n\narrowTest = () => {\n console.log('ArrowTest');\n}<\/code><\/pre>\n\n\n\n<\/p>\n\n\n\n
<\/span>\ub9cc\ub4e0 \ud568\uc218\ub97c \ud14d\uc2a4\ud2b8\ub85c \uc2e4\ud589\ud558\uae30<\/span><\/h2>\n\n\n\n\uc704\uc5d0 \ub9cc\ub4e0 \ud568\uc218\ub97c \uc2e4\ud589\ud558\ub294 \uac83\uc740 \ub2e4\uc74c\uacfc \uac19\ub2e4.<\/p>\n\n\n\n
\uc5c4\uccad \uac04\ub2e8\ud558\ub2e4. <\/p>\n\n\n\n
this['test']()\nthis['arrowTest']()<\/code><\/pre>\n\n\n\n\uc8fc\uc758\ud560 \uac83\uc740 this\uc5d0 \ub300\ud55c \uac1c\ub150\uc744 \uc798 \uc54c\uace0 \uc788\uc5b4\uc57c \uc0ac\uc6a9 \uc2dc \ubb38\uc81c\uac00 \ub418\uc9c0 \uc54a\uc744 \uac83\uc774\ub2e4. <\/p>\n\n\n\n
this\ub97c \uc0c1\uc18d \ubc1b\ub294\uc9c0 \uc548\ubc1b\ub294\uc9c0\uc5d0 \ub530\ub77c\uc11c \ub2ec\ub77c\uc9c8\ud14c\ub2c8 \ub9d0\uc774\ub2e4. <\/p>\n","protected":false},"excerpt":{"rendered":"
\uc0c1\ud669\uc5d0 \ub530\ub77c\uc11c \ud638\ucd9c\ud558\ub294 \ud568\uc218\uac00 \uc788\ub2e4. \uc0c1\ud669\uc5d0 \ub530\ub77c \ub3d9\uc801\uc73c\ub85c \ud638\ucd9c\ud558\ub294 \ud568\uc218\uac00 \uad49\uc7a5\ud788 \ub2e4\uc591\ud558\uace0 \ub9ce\ub2e4\uba74 if\ubb38\uc774\ub098 case\ubb38\ubcf4\ub2e4\ub294 ‘\ubb38\uc790\uc5f4’\uc744 \ud1b5\ud574\uc11c \ud638\ucd9c\ud558\ub294 \ubc29\ubc95\uc774 \uc788\uc9c0 \uc54a\uc744\uae4c? \ud558\ub2e4\uac00 \ucc3e\uc558\ub358 \uac83\uc778\ub370, \uacf5\uc720 \ud574\ubcf8\ub2e4. \uc5b8\uc81c \uc0ac\uc6a9\ud558\ub294\uac00? \uc5b8\uc81c \uc0ac\uc6a9\ud558\ub294\uac00 ? \ub9d0 \uadf8\ub300\ub85c String \ubb38\uc790 \uadf8\ub300\ub85c \ud568\uc218\ub97c \ud638\ucd9c\ud560 \ub54c \uc0ac\uc6a9\ud588\uc5c8\ub2e4. \ub3d9\uc801\uc778 \ud14d\uc2a4\ud2b8\ub85c \ud568\uc218\ub97c \ud638\ucd9c \ud558\ub294 \ub54c\uac00 \uc5b8\uc81c\uc600\ub0d0\uba74, Select Option \ud0dc\uadf8\ub97c \uc774\uc6a9\ud574\uc11c, \uc120\ud0dd\ud55c \uac83\uc5d0 \ub300\ud55c \uc18d\uc131 … Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-273","post","type-post","status-publish","format-standard","hentry","category-information"],"yoast_head":"\n[JavaScript] \ub3d9\uc801\uc73c\ub85c \ubcc0\ud558\ub294 \ubb38\uc790\ub85c \ud568\uc218 \ud638\ucd9c\ud558\uae30 - \uace0\uc6b4\uadf8\ubbf8<\/title>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\t\n\t\n\t\n