๊ฐœ๋ฐœ๋„๊ตฌ(Tool)

[VSCODE] PHP๊ฐœ๋ฐœ์ž ๋‚ด๊ฐ€์“ฐ๋Š” ํ™•์žฅ ํ”Œ๋Ÿฌ๊ทธ์ธ

๐Ÿป๊ณฐ์ด๐Ÿป 2023. 2. 2.
728x90

 

์ธ์‚ฌ๋ง

 

์•ˆ๋…•ํ•˜์„ธ์š” ๐Ÿป๊ณฐ์ด์—์š”! 

 

ํ˜„์žฌ VSCODE๋กœ PHP๋ฅผ์‚ฌ์šฉํ•˜๊ณ  ์žˆ๋Š”๋ฐ์š”.

 

์ œ๊ฐ€ ์“ฐ๋Š” ํ™•์žฅ ํ”Œ๋Ÿฌ๊ทธ์ธ ๊ฐ„๋‹จํ•˜๊ฒŒ ์†Œ๊ฐœํ•˜๋ฉด์„œ ๋ง์”€๋“œ๋ฆฌ๋„๋ก ํ•˜๊ฒ ์Šต๋‹ˆ๋‹ค.

 

์šฐ์„  VSCODE ํ”„๋กœ๊ทธ๋žจ์ด์—†๋‹ค๋ฉด ์•„๋ž˜์˜ ํฌ์ŠคํŒ…์„ ์ฐธ๊ณ ํ•˜์„ธ์š”.

 

VSCode(Visual Studio Code) ๋‹ค์šด๋กœ๋“œ ๋ฐ Python(ํŒŒ์ด์ฌ) ์„ค์น˜ ํ•˜๊ธฐ

์•ˆ๋…•ํ•˜์„ธ์š” ๊ณฐ์ด์—์š”:) ๋‚ ์”จ๊ฐ€ ๋งŽ์ด ์Œ€์Œ€ํ•˜๊ตฐ์š”.. ๋‹ค๋“ค ๊ฐ๊ธฐ ์กฐ์‹ฌํ•˜์„ธ์š”! ์˜ค๋Š˜์€ VSCode ์„ค์น˜ ๋ฐฉ๋ฒ•๊ณผ VSCode๋กœ ํŒŒ์ด์ฌ ์„ค์น˜ํ•˜๋Š” ๋ฐฉ๋ฒ•์— ๋Œ€ํ•ด์„œ ์•Œ์•„๋ณด๋„๋ก ํ•˜๊ฒ ์Šต๋‹ˆ๋‹ค. Visual Studio Code ๋ž€? ๋งˆ์ดํฌ๋กœ์†Œ

easy-developmentbear.tistory.com

 

๋‚ด๊ฐ€์“ฐ๋Š” ํ™•์žฅํ”„๋กœ๊ทธ๋žจ

 

 

1. PHP Intelephense

 

๋ชจ๋“ ํŒŒ์ผ๋“ค์—๋Œ€ํ•œ ๊ตฌ๋ฌธ์˜ค๋ฅ˜๋ฅผ ์žก์•„์ฃผ๋Š” ๊ธฐํŠนํ•œ ๋…€์„!

 

 

 

1 - 1 ์‚ฌ์šฉ๋ฐฉ๋ฒ•

์„ค์น˜ ํ•˜๋ฉด ๋์ด๋‹ค.

 

์‚ฌ์šฉ ์ „

 

์‚ฌ์šฉ์•ˆํ• ๋•Œ์—๋Š” ์ €๋ ‡๊ฒŒ ๊ตฌ๋ฌธ๊ณผ ๋งž์ง€์•Š๋Š” ํ…์ŠคํŠธ๊ฐ€ ๋“ค์–ด๊ฐ€์žˆ์Œ์—๋„ ๋ถˆ๊ตฌํ•˜๊ณ  ์•„๋ฌด๋Ÿฐ ์•Œ๋ฆผ์ด์—†๋‹ค.

 

์‚ฌ์šฉ ํ›„

 

์‚ฌ์šฉ ํ›„์—๋Š” ๋ณด๋Š”๊ฑฐ์™€๊ฐ™์ด ๋นจ๊ฐ„์ƒ‰ ๋ฐ‘์ค„ ๋ฐ ์•„๋ž˜์˜ ๋ฌธ์ œ ์ฐฝ์— ๋‚˜์˜ค๊ฒŒ ๋œ๋‹ค.

 

์•„ ์ฐธ! ํŒŒ์ผ์ด๋ฆ„์—๋„ ๋ถ‰์€์ƒ‰์œผ๋กœ ํ‘œ์‹œ๊ฐ€ ๋œ๋‹ค.

 

์—ฌ๋Ÿฌ๋ชจ๋กœ ํšจ์ž ํ”Œ๋Ÿฌ๊ทธ์ธ์ด๋‹ค.

 

1 - 2 ์„ค์น˜

 

https://marketplace.visualstudio.com/items?itemName=bmewburn.vscode-intelephense-client .

 

PHP Intelephense - Visual Studio Marketplace

Extension for Visual Studio Code - PHP code intelligence for Visual Studio Code

marketplace.visualstudio.com

 

 

2. Format HTML in PHP

 

PHP์•ˆ์—์„œ HTML ์ฝ”๋“œ๋ฅผ ์ •๋ ฌํ•ด์ฃผ๋Š” ๊ธฐ๋Šฅ์ด๋‹ค.

 

 

2 - 1 ์‚ฌ์šฉ๋ฐฉ๋ฒ•

 

์šฐํด๋ฆญ > Format HTML in PHP ์„ ํƒ

 

๋‹จ์ถ•ํ‚ค

Ctrl + Alt + F

 

 

2 - 2 ์„ค์น˜ํ•˜๊ธฐ

 

https://marketplace.visualstudio.com/items?itemName=rifi2k.format-html-in-php 

 

Format HTML in PHP - Visual Studio Marketplace

Extension for Visual Studio Code - Provides formatting for the HTML code in PHP files using JSbeautify - Works well paired with a PHP formatting extension

marketplace.visualstudio.com

 

3. Korean Language Pack for Visual Studio Code

 

VSCODE๋ฅผ ํ•œ๊ธ€ํ™” ์‹œ์ผœ์ฃผ๋Š” ํ™•์žฅํ”„๋กœ๊ทธ๋žจ!

 

์˜์–ด๊ฐ€ ์ต์ˆ™ํ•˜์‹ ๋ถ„๋“ค์€ ๋ถˆํŽธํ•˜์‹ค์ˆ˜๋„์žˆ์ง€๋งŒ ์˜์–ด๊ฐ€ ๋ถˆํŽธํ•œ ์‚ฌ๋žŒ๋“ค์„ ์œ„ํ•œ! ํ™•์žฅํ”„๋กœ๊ทธ๋žจ ์ž…๋‹ˆ๋‹ค.

 

 

3 - 1์‚ฌ์šฉ๋ฐฉ๋ฒ•

 

์„ค์น˜๋งŒ ํ•˜๋ฉด ์ ์šฉ๋ฉ๋‹ˆ๋‹ค.

 

์„ค์น˜ ํ›„์— ์‹คํ–‰์ด ์ œ๋Œ€๋กœ ๋˜์ง€์•Š๋Š”๋‹ค๋ฉด VSCODE๋ฅผ ์žฌ์‹คํ–‰ ํ•ด์ฃผ์„ธ์š”.

 

3 - 2 ์„ค์น˜

 

https://marketplace.visualstudio.com/items?itemName=MS-CEINTL.vscode-language-pack-ko 

 

Korean Language Pack for Visual Studio Code - Visual Studio Marketplace

Extension for Visual Studio Code - Language pack extension for Korean

marketplace.visualstudio.com

 

4. Auto Close Tag

 

HTMLํƒœ๊ทธ๋ฅผ ์ž๋™์œผ๋กœ ๋‹ซ์•„์ฃผ๋Š” ํšจ์ž ํ”Œ๋Ÿฌ๊ทธ์ธ ์ž…๋‹ˆ๋‹ค.

 

 

4 - 1 ์‚ฌ์šฉ๋ฐฉ๋ฒ•

 

์„ค์น˜๋งŒ ํ•˜๋ฉด ์ ์šฉ๋จ.

 

 

 

4 - 2 ์„ค์น˜

 

https://marketplace.visualstudio.com/items?itemName=formulahendry.auto-close-tag 

 

Auto Close Tag - Visual Studio Marketplace

Extension for Visual Studio Code - Automatically add HTML/XML close tag, same as Visual Studio IDE or Sublime Text

marketplace.visualstudio.com

 

 

5. Auto Rename Tag

 

ํƒœ๊ทธ๋ฅผ ์ˆ˜์ •ํ• ๋•Œ ํƒœ๊ทธ๋งˆ์ง€๋ง‰ ๋ถ€๋ถ„๋„ ๊ฐ™์ด ์ˆ˜์ •์ด ๋˜๋Š” ์ •๋ง ํŽธ๋ฆฌํ•œ ํ”Œ๋Ÿฌ๊ทธ์ธ

 

 

5 - 1 ์‚ฌ์šฉ๋ฐฉ๋ฒ•

 

์„ค์น˜๋งŒ ํ•˜๋ฉด ๋๋‚œ๋‹ค.

 

์‚ฌ์šฉ ์ „

์‚ฌ์šฉ ํ›„

 

5 - 2 ์„ค์น˜

 

https://marketplace.visualstudio.com/items?itemName=formulahendry.auto-rename-tag 

 

Auto Rename Tag - Visual Studio Marketplace

Extension for Visual Studio Code - Auto rename paired HTML/XML tag

marketplace.visualstudio.com

 

6. Material Icon Theme

 

ํŒŒ์ผ๋ณ„๋กœ ์•„์ด์ฝ˜์œผ๋กœ ์–ด๋– ํ•œ ํ™•์žฅ์ž๋ฅผ ๊ฐ–๋Š”์ง€์—๋Œ€ํ•œ ๊ฐ€๋…์„ฑ์„ ๋†’์—ฌ์ฃผ๋Š” ์•„์ฃผ์•„์ฃผ ํŽธํ•œ ํ”Œ๋Ÿฌ๊ทธ์ธ์ด๋‹ค.

 

 

6 - 1 ์‚ฌ์šฉ๋ฐฉ๋ฒ•

์„ค์น˜๋งŒ ํ•˜๋ฉด ์•Œ์•„์„œ ์•„์ด์ฝ˜์ด ๋ฐ”๋€๋‹ค.

 

์‚ฌ์šฉ ์ „

 

์šฐ์„  ํŒŒ์ผ๋ช…์€ ํ•„์š”์—†์œผ๋‹ˆ ๋‹ค ๊ฐ€๋ ธ๋‹ค.

 

ํ•ด๋‹น ํ”Œ๋Ÿฌ๊ทธ์ธ์„ ์‚ฌ์šฉํ•˜์ง€์•Š์•„๋„ ๊ธฐ๋ณธ์ ์œผ๋กœ ํŒŒ์ผ ํ™•์žฅ์ž์— ๋”ฐ๋ผ ๊ตฌ๋ถ„์ด ๋˜๊ธดํ•œ๋‹ค.

 

ํ•˜์ง€๋งŒ ์‚ฌ์šฉ ํ›„์— ์ด๋ฏธ์ง€๋ฅผ ๋ณด๋ฉด ํ™•์‹คํ•˜๊ฒŒ ์™œ ์จ์•ผํ•˜๋Š”์ง€๋ฅผ ์•Œ๋ ค์ค€๋‹ค.

 

์œ„์— ๊บผ๋ž‘ ํ™•์‹คํžˆ ๋น„๊ต๊ฐ€ ๋œ๋‹ค.

phpํŒŒ์ผ์€ ํŒŒ์ผ๋ช… ์•ž์— php ๋กœ๊ณ ๊ฐ€ ๋ถ™๋Š”๋‹ค.

htmlํŒŒ์ผ์€ html๋กœ๊ณ ๊ฐ€ ๋ถ™๊ณ  ์ด๋Ÿฐ์‹์ด๋‹ค.

ํŒŒ์ผ๊ณผ ํด๋”๋„ ์•„์ด์ฝ˜์œผ๋กœ ๋ฐ”๊ฟ”์ค€๋‹ค.

 

php,html๋งŒ ์ง€์›ํ•˜๋Š”๊ฒŒ์•„๋‹ˆ๋‹ค.

๋ฌด์ˆ˜ํžˆ ๋งŽ์€ ๊ฐœ๋ฐœ์–ธ์–ด ์•„์ด์ฝ˜๋“ค..

 

์ด ์™ธ์—๋„ ๋ฌด์ˆ˜ํžˆ ๋งŽ์€ ๊ฐœ๋ฐœ์–ธ์–ด๋“ค์—๋Œ€ํ•œ ํ™•์žฅ์ž. ํด๋”์—๋Œ€ํ•œ ๋„ค์ด๋ฐ์„ ๋ณด๊ณ  ์ž๋™์œผ๋กœ ๋งž์ถฐ์ฃผ๋‹ˆ ์ด๋ณด๋‹ค ๋” ํŽธํ• ์ˆ˜์—†๋‹ค.

 

6 - 2 ์„ค์น˜

https://marketplace.visualstudio.com/items?itemName=PKief.material-icon-theme 

 

Material Icon Theme - Visual Studio Marketplace

Extension for Visual Studio Code - Material Design Icons for Visual Studio Code

marketplace.visualstudio.com

 

์šฐ์„  ๋‚˜๋Š” ์ด๋Ÿฌํ•œ ํ™•์žฅํ”„๋กœ๊ทธ๋žจ์„ ์‚ฌ์šฉํ•œ๋‹ค.

 

๋” ํŽธํ•œ ํ˜น์€ ๋” ์œ ์šฉํ•œ ํ™•์žฅํ”„๋กœ๊ทธ๋žจ๋„ ๋งŽ๊ฒ ์ง€๋งŒ

 

๊ฐœ๋ฐœ์— ํ•„์š”ํ•œ๊ฒƒ๋งŒ ๋”ฑ ์ •ํ•ด๋†“๊ณ  ๋‹ค์šด๋ฐ›์•„์„œ ์“ด๋‹ค.

 

PHP๋ฉด ๋ฌผ๋ก  PHPStorm์ด ์ œ์ผ ์ข‹๊ฒ ์ง€๋งŒ..

 

VSCODE๋Š” ๋ฌด๋ฃŒ๋ผ์„œ ๋งŽ์€ ์‚ฌ๋žŒ๋“ค๊ณผ ๊ธฐ์—…์—์„œ ์‚ฌ์šฉํ•œ๋‹ค.

 

์ด๊ฒƒ์œผ๋กœ ํฌ์ŠคํŒ…์„ ๋งˆ์น˜๊ฒ ์Šต๋‹ˆ๋‹ค.

 

๊ธด ๊ธ€ ์ฝ์–ด์ฃผ์…”์„œ ๊ฐ์‚ฌํ•ฉ๋‹ˆ๋‹ค.

 

๋ฐ˜์‘ํ˜•

๋Œ“๊ธ€