๋งํฌ๋ค์ด์ ์ผ๋ฐ ํ ์คํธ๋ก ์์์ด ์๋ ๋ฌธ์๋ฅผ ์์ฑํ๋ ๋ฐ ์ฌ์ฉ๋๋ ๊ฒฝ๋ ๋งํฌ์ ์ธ์ด๋ค. ์ผ๋ฐ ๋งํฌ์ ์ธ์ด์ ๋นํด ๋ฌธ๋ฒ์ด ์ฝ๊ณ ๊ฐ๋จํ ๊ฒ์ด ํน์ง์ด๋ฉฐ, ๋งํฌ๋ค์ด์ ์ด์ฉํด ์์ฑ๋ ๋ฌธ์๋ ์ฝ๊ฒ HTML๋ก ๋ณํ ๊ฐ๋ฅํ๋ค.
๊ทธ๋ ๋ค๋ฉด ๋งํฌ์ ์ธ์ด๋ ๋ฌด์์ผ๊น?
๋งํฌ์ ์ธ์ด(Markup Language)
ํ๊ทธ(tag)๋ฅผ ์ฌ์ฉํด ๋ฌธ์๋ ๋ฐ์ดํฐ์ ๋ ผ๋ฆฌ์ ์ธ ๊ตฌ์กฐ๋ฅผ ๋ช ์ํ๊ธฐ ์ํ ๊ท์น๋ค์ ์ ์ํ ์ปดํจํฐ ์ธ์ด๋ฅผ ๋ปํ๋ค. ์ผ๋ฐ์ ์ผ๋ก ๋ฐ์ดํฐ๋ฅผ ๊ธฐ์ ํ๋ ์ ๋๋ก๋ง ์ฌ์ฉ๋๊ธฐ์ ํ๋ก๊ทธ๋๋ฐ ์ธ์ด์๋ ๊ตฌ๋ณ๋๋ค.
๊ฐ์ฅ ์ ์๋ ค์ง ๋งํฌ์ ์ธ์ด๋
HTML(Hypertext Markup Language)
์ด๋ค.
๋ค์ ๋งํด์ ๋งํฌ๋ค์ด์ ํ๊ทธ๋ก ์ด๋ฃจ์ด์ง ๋ณต์กํ ๋งํฌ์ ์ธ์ด๋ฅผ ๋์ฒดํ๊ธฐ ์ํด ๋ง๋ค์ด์ง ๋งํฌ์ ์ ํ์ํ์ด๋ค. ๊ทธ๋์ ๋ณดํต์ ๋งํฌ์ ์ธ์ด๋ณด๋ค ์ดํด, ํธ์ง, ์ฒ๋ฆฌํ๊ธฐ๊ฐ ์ฝ๋ค.
ํ์ง๋ง, ๋งํฌ๋ค์ด์ ๋ชจ๋ HTML์ ๋ฌธ๋ฒ์ ๋์ ํ์ง ๋ชปํ๋ค.
์ ๋ชฉ | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ |
---|---|---|
h1 | # or == | <h1>โฆ</h1> |
h2 | ## or -- | <h2>โฆ</h2> |
h3 | ### | <h3>โฆ</h3> |
h4 | #### | <h4>โฆ</h4> |
h5 | ##### | <h5>โฆ</h5> |
h6 | ###### | <h6>โฆ</h6> |
์ ๋ชฉ์ <h1>
๋ถํฐ <h6>
๊น์ง ์๋ค. #
์ ๊ฐ์์ ๋ฐ๋ผ ๋๋ <h>
ํ๊ทธ๋ฅผ ์ด์ฉํด ํํํ ์ ์์ผ๋ฉฐ, <h1>
๊ณผ <h2>
๋ =
์ -
๋ฅผ ๊ฐ๊ฐ 2๊ฐ ์ด์์ฉ ์ฌ์ฉํด ๋์ฒดํ ์ ์๋ค.
# This is a h1.
## This is a h2.
### This is a h3.
#### This is a h4.
##### This is a h5.
###### This is a h6.
This is a h1.
==
This is a h2.
--
<h1>This is a h1.</h1>
<h2>This is a h2.</h2>
<h3>This is a h3.</h3>
<h4>This is a h4.</h4>
<h5>This is a h5.</h5>
<h6>This is a h6.</h6>
This is a h1.
This is a h2.
This is a h3.
This is a h4.
This is a h5.
This is a h6.
This is a h1.
This is a h2.
This is a h1.
This is a h2.
This is a h3.
This is a h4.
This is a h5.
This is a h6.
๊ฐ์กฐ | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ |
---|---|---|
๊ธฐ์ธ์ด๊ธฐ | *โฆ* or _โฆ_ | <em>โฆ</em> |
๊ตต๊ฒ | **โฆ** or __โฆ__ | <strong>โฆ</strong> |
์ทจ์์ | ~~โฆ~~ | <del>โฆ</del> |
๊ธ์์ | <span style="color:โฆ">โฆ</span> |
๊ธฐ์ธ์ด๊ธฐ(Italic)
, ๊ตต๊ฒ(Bold)
, ์ทจ์์ (Strikethrough)
, ๊ธ์์
๋ฑ์ ๊ธฐ๋ณธ์ ์ธ ์คํ์ผ์ ์๋์ ๊ฐ์ด ์์ฑํ ์ ์๋ค. ๋ฐ์ค(Underscore)
์ <u>
ํ๊ทธ๋ก ํํํ ์ ์๋๋ฐ, velog ์์๋ ์ ์ฉ์ด ๋์ง์๋๋ค.
๊ธ์์์ ์๋ช
, RGB, HEX ์ฝ๋๋ฅผ ์ด์ฉํด ๋ํ๋ผ ์ ์๋ค.
โ๏ธ RGB, HEX ์์ ์ฝ๋๋ฅผ ํ์ธํ ์ ์๋ ์ฌ์ดํธ โ๏ธ
*Italic*
_Italic_
<em>Italic</em>
**Bold**
__Bold__
<strong>Bold</strong>
~~strikethrough~~
<del>strikethrough</del>
<span style="color:red">red</span>
<span style="color:#2c4861">#2c4861</span>
<span style="color:rgb(91, 33, 158)">rgb(91, 33, 158)</span>
Italic
Italic
Italic
Bold
Bold
Bold
strikethrough
strikethrough
red
#2c996e
rgb(91, 33, 158)
์ฝ๋๋ธ๋ญ | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ |
---|---|---|
์ธ๋ผ์ธ ์ฝ๋ | ` โฆ ` | <code>โฆ</code> |
ํ ์ค ์ฝ๋๋ธ๋ญ | Tab ํค | |
์ฌ๋ฌ ์ค ์ฝ๋๋ธ๋ญ | ``` โฆ ``` | <pre>โฆ</pre> |
์ธ๋ผ์ธ ์ฝ๋๋ ํจ์ ์ ์ ๋๋ ๋ณ์ ์ด๋ฆ๊ณผ ๊ฐ์ด ๋จ๋ฝ ๋ด์์ ์งง์ ์ฝ๋ ์กฐ๊ฐ์ ๊ฐ์กฐํ ๋ ์ฌ์ฉํ๋ค. ๋ฐฑํฑ(`)
๋๋ <code>
ํ๊ทธ๋ฅผ ์ด์ฉํด ํํํ ์ ์์ผ๋ฉฐ, ๋ฐฑํฑ ๋ฌธ์๋ ESC ํค ๋ฐ์ ์๋ ๋ฐ์ดํ๋ฅผ ์๋ฏธํ๋ค.
`This is a line.`
<code>This is a line.</code>
This is a line.
This is a line.
ํ ์ค์ง๋ฆฌ ์ฝ๋๋ธ๋ญ์ Tab
ํค๋ฅผ ์ด์ฉํด์ ํํํ ์ ์๋ค. ๋ค๋ง, Tab ํค ์ฌ์ฉ์ ์ด์ ๋ฌธ์ฅ์ผ๋ก๋ถํฐ Enter 2๋ฒ ๋๋ฅธ ํ ํํ์ด ๋๋ค.
Tab
This is a line.
This is a line.
์ฌ๋ฌ ์ค์ ์ฝ๋๋ธ๋ญ์ ๋ฐฑํฑ(`)
3๊ฐ์ <pre></pre>
๋ฅผ ์ด์ฉํด์ ํํํ ์ ์๋ค. ๋ฐฑํฑ 3๊ฐ ๋ค์ ์ธ์ด ์ด๋ฆ์ ์ฐ๋ฉด ์ฝ๋ ํ์ด๋ผ์ดํธ
๋ฅผ ํํํ ์ ์๋ค.
```
Inline Code
for multiple lines.
```
``` c
#include <stdio.h>
int main()
{
printf("Hello world!\n");
return 0;
}
```
``` python
num_list = ['one', 'two', 'three']
for num in num_list:
print(num)
```ใ
<pre>
Inline Code
for multiple lines.
</pre>
Inline Code for multiple lines.
#include <stdio.h> int main() { printf("Hello world!\n"); return 0; }
num_list = ['one', 'two', 'three'] for num in num_list: print(num)
Inline Code for multiple lines.
๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ | |
---|---|---|
์ธ์ฉ๊ตฌ | > | <Blockquote>โฆ</Blockquote> |
์ธ์ฉ๊ตฌ๋ ๊บฝ์ ๊ดํธ(>)
๋๋ <Blockquote>
ํ๊ทธ๋ฅผ ์ด์ฉํด์ ํํํ ์ ์๋ค. ๊บฝ์ ๊ดํธ์ ๊ฐ์์ ๋ฐ๋ผ์ ์ด์ค, ์ผ์ค ์ด์์ผ๋ก ์ฌ์ฉ์ด ๊ฐ๋ฅํ๋ค.
> This is a BlockQuote 1.
>> This is a BlockQuote 1-1.
>>> his is a BlockQuote 1-2.
<Blockquote>This is a BlockQuote 2.</Blockquote>
This is a BlockQuote 1.
This is a BlockQuote 1-1.
his is a BlockQuote 1-2.
This is a BlockQuote 2.
๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ | |
---|---|---|
๊ฐํ | <br/> |
๋ฌธ๋จ ๊ฐ๊ฒฉ์ ์ค ๋ฐ๊ฟ(Enter)
๋ก ๋ํ๋ด๋ฉฐ, ์ฌ๋ฌ ๋ฒ์ ์ค ๋ฐ๊ฟ
์ <br/>
๋ก ํํ ํ ์ ์๋ค.
This is the first paragraph. <br/><br/>
This is the second paragraph.
This is the first paragraph.
This is the second paragraph.
๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ | |
---|---|---|
์ํ์ | **** or ____ or -- -- | <hr/> |
์ํ์ ์ *
, _
, -
๋ฅผ ๊ฐ๊ฐ 3๊ฐ ์ด์ ์์ฑํ๊ฑฐ๋ <hr/>
ํ๊ทธ๋ก ํํํ ์ ์๋ค. ์ด๋, -
๋ <h2>
ํค๋๋ก ์ธ์ํ ์ ์์ผ๋ ์ฃผ์ํด์ ์ฌ์ฉํด์ผ ํ๋ค.
****
____
-- --
<hr/>
๋ชฉ๋ก | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ |
---|---|---|
Ordered List | ์ซ์. | <ol><li>โฆ</li></ol> |
Unordered List | *, -, + | <ul><li>โฆ</li></ul> |
์์๋ฅผ ํ๊ธฐํ๋ ๋ชฉ๋ก์ ์ซ์.
๋๋ <ol>
ํ๊ทธ์ <li>
ํ๊ทธ์ ์กฐํฉ์ ์ด์ฉํด์ ํํํ ์ ์๋ค.
HTML ํ๊ทธ๋ฅผ ์ฌ์ฉํด ์์ํ๋ ๋ฒํธ๋ฅผ ์ง์ ํ๋ ค๋ฉด <ol start="โฆ">
๋ก ์์ฑํ๋ค. ๊ทธ๋ฆฌ๊ณ ํน์ ๋ชฉ๋ก์ ๋ฒํธ๋ฅผ ์ง์ ํ๋ ค๋ฉด <li value="โฆ"
> ์ ์ฌ์ฉํ๋ค.
1. First
2. second
<ol>
<li> First </li>
<li> Second </li>
</ol>
<ol start="5">
<li> Five </li>
<li value="9"> nine </li>
<li> ten </li>
</ol>
- First
- second
- First
- Second
- Five
- nine
- ten
์์๊ฐ ์๋ ๋ชฉ๋ก์ *
, -
, +
์ค ์๋ฌด๊ฑฐ๋ ์ด์ฉํ๋ฉด ํํํ ์ ์๋ค. ๋ํ, <ul>
ํ๊ทธ์ <li>
ํ๊ทธ์ ์กฐํฉ์ผ๋ก ํํํ ์ ์๋ค.
* list
- list
+ list
<ul>
<li>list</li>
<li>list</li>
</ul>
- list
- list
- list
- list
- list
ํ
์ด๋ธ์ |
๋ก ๊ตฌ๋ถํด ์ ์ ๋ง๋ค๊ณ -
๋ก ์ ๋ชฉ๊ณผ ๋ฐ์ดํฐ ์์ญ์ ๋๋๋ค. ์ ๋ ฌ์ :
์ ์ด์ฉํด ์ค๋ฅธ์ชฝ/๊ฐ์ด๋ฐ/์ผ์ชฝ ์ ๋ ฌ์ ํ ์ ์์ง๋ง, velog ์์ ์ ์ฉ์ด ์๋๋ค.
| Title 1 | Title 2 | Title 3|
| :--- | :---: | ---: |
| Left | Center | Right |
| Data | Data | Data |
Title 1 Title 2 Title 3 Left Center Right Data Data Data
๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ | |
---|---|---|
์ด๋ฏธ์ง |  | <img alt="์ ๋ชฉ" src="๋งํฌ"/> |
์ด๋ฏธ์ง๋ฅผ ์ฒจ๋ถํ ๋, 
๋๋ <img alt="์ ๋ชฉ" src="๋งํฌ"/>
ํ๊ทธ๋ฅผ ์ด์ฉํด ํํํ ์ ์๋ค. ๋ณต์ฌ/๋ถ์ฌ๋ฃ๊ธฐ๋ฅผ ์ฌ์ฉํด๋ ์๊ด์๋ค(์๋์ผ๋ก ํํ๋๋ค).

<img alt="ocean" src="https://cdn.pixabay.com/photo/2021/08/08/10/34/ocean-6530523_960_720.jpg"/>
๋งํฌ | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ | HTML ํ๊ทธ |
---|---|---|
์ธ๋ผ์ธ ๋งํฌ | [์ ๋ชฉ](๋งํฌ) | <a href="โฆ">โฆ</a> |
URL ๋งํฌ | <๋งํฌ> | |
์ฐธ์กฐ ๋งํฌ | [์ ๋ชฉ]:๋งํฌ [์ ๋ชฉ] | |
์ด๋ฏธ์ง ๋งํฌ | [](์ฐ๊ฒฐํ๊ณ ์ ํ๋ ๋งํฌ) |
[My velog](https://velog.io/@thwlsdl1202)
<a href="https://velog.io/@thwlsdl1202">My velog</a>
<https://velog.io/@thwlsdl1202>
[My velog]:<https://velog.io/@thwlsdl1202>
My velog ๋ฐ๋ก๊ฐ๊ธฐ : [My velog] ๋ก ๋๋ฌ์ค์ธ์~
My velog ๋ฐ๋ก๊ฐ๊ธฐ : My velog ๋ก ๋๋ฌ์ค์ธ์~
[](์ฐ๊ฒฐํ ๋งํฌ)
[](https://velog.io/@thwlsdl1202)
์ด์ค์ผ์ดํ ๋ฌธ์ | ๋งํฌ๋ค์ด ๋ฌธ๋ฒ |
---|---|
backslash | \\ |
backtick | \ ` |
curly braces | \{ , \} |
square brackets | \[ , \] |
hash mark | \# |
asterisk | \* |
plus | \+ |
minus | \- |
๋งํฌ๋ค์ด์์๋ *, `, \์ ๊ฐ์ด ํน๋ณํ ์๋ฏธ๋ฅผ ๊ฐ์ง ๋งํฌ์ ๋ฌธ์ ๊ทธ ์์ฒด๋ฅผ ์ป๊ธฐ ์ํด์ ๋ฐฑ ์ฌ๋์๋ก ์ด์ค์ผ์ดํ ์ฒ๋ฆฌํ์ฌ ์ฌ์ฉํ๋ค. ์ฐธ๊ณ ๋ก ํ์์ ๋งํฌ๋ค์ด ๋ฌธ๋ฒ์ด๋ HTML ํ๊ทธ๋ฅผ ์ฌ์ฉํ ๋ ๋ฐฑํฑ์ผ๋ก ๊ฐ์ธ๋ ์๊ด์๋ค.
\\
\`
\{
\}
\[
\]
\#
\*
\+
\-
\
`
{
}
[
]
#
*
+
-
velog ๋ฅผ ๋ณธ๊ฒฉ์ ์ผ๋ก ์์ํ๊ธฐ ์ ๋ง์ด ์ฌ์ฉํ ๊ฒ ๊ฐ์ ๋งํฌ๋ค์ด ๋ฌธ๋ฒ์ ๋ํด ์์๋ณด๊ธฐ ์ํด ์์ฑํ ๊ธ ์ด๋ค. '๋'๋ฅผ ์ํด ์ ๋ฆฌํ ๊ธ์ด๊ธฐ ๋๋ฌธ์ ์ด๋ฏธ ์๊ณ ์๊ฑฐ๋ ์ฐ์ง ์์ ๊ฒ ๊ฐ์ ์ด๋ชจ์ง, ์ฒดํฌ๋ฐ์ค ๋ฑ์ ๋ด์ฉ์ ์ ๋ฆฌํ์ง ์์๋ค.
[ ์ฐธ๊ณ ํ ๋ธ๋ก๊ทธ ]