JavaScript

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๋ฐฐ์—ด push, pop, shift, unshift ํ•จ์ˆ˜์˜ ๊ฐœ๋…๊ณผ ์‚ฌ์šฉ๋ฒ•

martinooo 2024. 7. 5. 18:04

 

 

 

 

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ ์ค‘์š”ํ•œ ๋ฐฐ์—ด ์‚ฌ์ „ ์ง€์‹ ๊ณต๋ถ€ํ•˜๊ธฐ


 


๋ฐฐ์—ด reduce() ํ•จ์ˆ˜ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐ

https://cometruedream.tistory.com/256

 

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ๋ฐฐ์—ด(array) reduce ํ•จ์ˆ˜์˜ ๊ฐœ๋…๋ฐ ํ™œ์šฉ๋„ ๋†’์€ ์‚ฌ์šฉ๋ฒ•

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ ์ค‘์š”ํ•œ ๋ฐฐ์—ด ์‚ฌ์ „ ์ง€์‹ ๊ณต๋ถ€ํ•˜๊ธฐ ๋ฐฐ์—ด join() ํ•จ์ˆ˜ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐhttps://cometruedream.tistory.com/254 [์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ๋ฐฐ์—ด(array)์„ ์œ ์šฉํ•˜๊ฒŒ ํ™œ์šฉํ•  ์ˆ˜ ์žˆ๋Š” join ํ•จ์ˆ˜ ๊ฐœ

cometruedream.tistory.com

 

 

๋ฐฐ์—ด join() ํ•จ์ˆ˜ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐ

https://cometruedream.tistory.com/254

 

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ๋ฐฐ์—ด(array)์„ ์œ ์šฉํ•˜๊ฒŒ ํ™œ์šฉํ•  ์ˆ˜ ์žˆ๋Š” join ํ•จ์ˆ˜ ๊ฐœ๋… ๋ฐ ์‚ฌ์šฉ๋ฒ•

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ๋ฐฐ์—ด์€ javascript์—์„œ ๊ฐ€์žฅ ์ค‘์š”ํ•œ ๋ฐ์ดํ„ฐ ์ž๋ฃŒ๊ตฌ์กฐ ์ค‘ ํ•˜๋‚˜์ž…๋‹ˆ๋‹ค.๋ฐฐ์—ด์— ๋‚ด์žฅํ•จ์ˆ˜๋ฅผ ํ™œ์šฉํ•˜๋Š” ๊ฒƒ์€ javascript์—์„œ ์ค‘์š”ํ•œ ๋ถ€๋ถ„ ์ค‘ ํ•˜๋‚˜์ด๋ฉฐ join() ๋ฐฐ์—ด ๋ฉ”์„œ๋“œ๋Š” ๋ฐฐ์—ด์„ ํ•ฉ

cometruedream.tistory.com

 

 

๋ฐฐ์—ด map(), forEach() ์ธ๊ธฐ ์žˆ๋Š” ๋ฉ”์„œ๋“œ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐ

https://cometruedream.tistory.com/253

 

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ๋ฐฐ์—ด(array)์„ ์ฒ˜๋ฆฌํ•˜๋Š” ์ธ๊ธฐ์žˆ๋Š” ๋ฉ”์†Œ๋“œ map(), forEach() ๊ฐœ๋…๊ณผ ์ฐจ์ด์ 

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋Š” ํ˜„์žฌ ์›น/์•ฑ ๊ฐœ๋ฐœ ํŠธ๋ Œ๋“œ์—์„œ ํ•„์ˆ˜์ ์œผ๋กœ ์‚ฌ์šฉ๋˜๋Š” ํ”„๋กœ๊ทธ๋ž˜๋ฐ ์–ธ์–ด์ž…๋‹ˆ๋‹ค. ์—ฌ๋Ÿฌ ์•„์ดํ…œ์„ ์ €์žฅํ•˜๋Š”๋ฐ ์‚ฌ์šฉ๋˜๋Š” ๋ฐฐ์—ด๊ณผ ์ด๋ฅผ ํŒŒ์‹ฑํ•˜๋ฉฐ ์ƒˆ๋กœ์šด ๋ฐ์ดํ„ฐ๋ฅผ

cometruedream.tistory.com

 

 

ํ™œ์šฉ๊ฐ€์น˜๊ฐ€ ์ข‹์€ every(), some() ํ•จ์ˆ˜ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐ

https://cometruedream.tistory.com/250

 

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ํ™œ์šฉ๊ฐ€์น˜๊ฐ€ ์ข‹์€ ๋‚ด์žฅํ•จ์ˆ˜์™€ every(), some() ํ•จ์ˆ˜์˜ ๊ฐœ๋… ๋ฐ ํ™œ์šฉ๋ฒ•

๐Ÿคท‍โ™‚๏ธ ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๋‚ด์žฅ ํ•จ์ˆ˜๋ž€?์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋ฅผ ํšจ์œจ์ ์œผ๋กœ ํ™œ์šฉํ•˜๋ ค๋ฉด ๋‚ด์žฅ ํ•จ์ˆ˜๋ฅผ ์ž˜ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.๋‚ด์žฅ ํ•จ์ˆ˜๋Š” ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ์—์„œ ๋ฏธ๋ฆฌ ์„ ์–ธ๋œ ํ•จ์ˆ˜๋กœ, ํ˜ธ์ถœ๋งŒ์œผ๋กœ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์Šต

cometruedream.tistory.com

 

 

์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๊ฐ์ฒด ์ƒ์„ฑ๊ณผ ์กฐ์ž‘, JSON, ๋ฉ”์„œ๋“œ ๊ฐœ๋…๊ณผ ์‚ฌ์šฉ๋ฒ•

https://cometruedream.tistory.com/261

 

[์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ] ๊ฐ€์žฅ ์ค‘์š”ํ•œ ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๊ฐ์ฒด ์ƒ์„ฑ๊ณผ ์กฐ์ž‘, JSON, ๋ฉ”์„œ๋“œ ๊ฐœ๋…๊ณผ ์‚ฌ์šฉ๋ฒ•

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ ์ค‘์š”ํ•œ ๋ฐฐ์—ด ์‚ฌ์ „ ์ง€์‹ ๊ณต๋ถ€ํ•˜๊ธฐ "> HTML ์‚ฝ์ž…๋ฏธ๋ฆฌ๋ณด๊ธฐํ•  ์ˆ˜ ์—†๋Š” ์†Œ์Šค ๋ฐฐ์—ด reduce() ํ•จ์ˆ˜ ์‚ฌ์šฉ๋ฒ•์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ธฐhttps://cometruedream.tistory.com/259 HTML ์‚ฝ์ž…๋ฏธ๋ฆฌ๋ณด๊ธฐํ•  ์ˆ˜ ์—†๋Š”

cometruedream.tistory.com

 

 

๐Ÿคท‍โ™‚๏ธ ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๋ฐฐ์—ด push, pop, shift, unshift๋ž€?


์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋Š” ๊ฐ์ฒด์ง€ํ–ฅ ํ”„๋กœ๊ทธ๋žจ์ด๋ฉฐ ์œ ์—ฐํ•˜๊ณ  ๊ฐ•๋ ฅํ•œ ์–ธ์–ด์ž…๋‹ˆ๋‹ค.

์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋Š” ๋™์ ์ธ ์–ธ์–ด๋กœ ๋ฐฐ์—ด์— ์š”์†Œ๋“ค์„ ์ถ”๊ฐ€, ์‚ญ์ œ๋ฅผ ํŽธ๋ฆฌํ•˜๊ฒŒ ๋„์™€์ฃผ๋Š” ์œ ์šฉํ•œ ๋‚ด์žฅํ•จ์ˆ˜๋“ค์ด ๋งŽ์Šต๋‹ˆ๋‹ค.

์œ ์šฉํ•œ ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜๋“ค ์ค‘์—์„œ๋„ push, pop, shift, unshift ํŠนํžˆ ๊ฐ€์žฅ ๋งŽ์ด ์‚ฌ์šฉ๋˜๋Š” ๋ฐฐ์—ด์˜ ๋‚ด์žฅํ•จ์ˆ˜๋“ค์ž…๋‹ˆ๋‹ค.

์ด 4๊ฐ€์ง€ ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜์— ๊ฐœ๋…๊ณผ ์˜ˆ์ œ์™€ ๊ฐ๊ฐ ๋‚ด์žฅํ•จ์ˆ˜๋“ค์˜ ์ฐจ์ด์ ์— ๋Œ€ํ•ด์„œ ์•Œ์•„๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค.

 

 

๐Ÿคท‍โ™‚๏ธ ๋ฐฐ์—ด์— ์œ ์šฉํ•œ ๋‚ด์žฅํ•จ์ˆ˜ ์˜ˆ์ œ


1. ๊ฐ€์žฅ ๋งŽ์ด ์‚ฌ์šฉ๋˜๋Š” ๋‚ด์žฅํ•จ์ˆ˜ push()

  • push() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ๋์— ์ƒˆ๋กœ์šด ์š”์†Œ์— ๊ฐ’์„ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค.
  • push() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana"];
console.log(fruits.push()); 
//๊ฒฐ๊ณผ๊ฐ’: 2 ๋ฐฐ์—ด์˜ ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

let fruits = ["apple", "banana"];
fruits.push('orange');
console.log(fruits)
//๊ฒฐ๊ณผ๊ฐ’: ["apple", "banana", "orange"]

 

์œ„์— ์˜ˆ์ œ์ฒ˜๋Ÿผ push() ํ•จ์ˆ˜๋งŒ ์„ ์–ธํ•˜๋ฉด ๋ฐฐ์—ด์— ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

push() ํ•จ์ˆ˜์— ๊ฐ’์„ ๋„ฃ์œผ๋ฉด ๋ฐฐ์—ด์˜ ๋งจ๋’ค์— ์ƒˆ๋กœ์šด ๊ฐ’์„ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

 

2. ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜ pop()

  • pop() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ๋งˆ์ง€๋ง‰ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค.
  • push() ํ•จ์ˆ˜๋Š” ์ œ๊ฑฐ๋œ ์š”์†Œ๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana", "orange"];
let removed = fruits.pop();

console.log(fruits); 
// ["apple", "banana"] ๋ฐฐ์—ด์— ๋งˆ์ง€๋ง‰ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค. 
console.log(removed); 
// removed ๋ณ€์ˆ˜์— ๋ฐฐ์—ด์— ๋งˆ์ง€๋ง‰ ๊ฐ’ "orange" ๋‹ด์Šต๋‹ˆ๋‹ค.

 

์œ„์— ์˜ˆ์ œ ์ฒ˜๋Ÿผ pop() ํ•จ์ˆ˜๋ฅผ ์„ ์–ธํ•˜๋ฉด ๋ฐฐ์—ด์— ๋งˆ์ง€๋ง‰์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•˜๊ณ  ๋ณ€์ˆ˜์— ์ œ๊ฑฐํ•œ ๋งˆ์ง€๋ง‰ ๊ฐ’์„ ๋‹ด์„ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

 

3. ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜ shift()

  • shift() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ์ฒซ ๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค.
  • shift() ํ•จ์ˆ˜๋Š” ์ œ๊ฑฐ๋œ ์š”์†Œ๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana", "orange"];
let removed = fruits.shift();

console.log(fruits); 
// ["banana", "orange"] ๋ฐฐ์—ด์— ์ฒซ๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค. 
console.log(removed); 
// removed ๋ณ€์ˆ˜์— ๋ฐฐ์—ด์— ์ฒซ๋ฒˆ์งธ ๊ฐ’ "apple" ๋‹ด์Šต๋‹ˆ๋‹ค.

 

pop() ๋‚ด์žฅํ•จ์ˆ˜ ๋ฐ˜๋Œ€๋กœ ๋ฐฐ์—ด์˜ ์ฒซ๋ฒˆ์งธ ๊ฐ’์„ ์ œ๊ฑฐํ•˜๊ณ  ๋ณ€์ˆ˜์— ์ œ๊ฑฐํ•œ ์ฒซ ๋ฒˆ์งธ ๊ฐ’์„ ๋‹ด์Šต๋‹ˆ๋‹ค.

 

4. ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜ unshift()

  • unshift() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ์ฒซ ๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค.
  • unshift() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์˜ ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana", "orange"];
fruits.unshift("grape");

console.log(fruits.unshift()) 
//๊ฒฐ๊ณผ๊ฐ’: 4
console.log(fruits); 
//๊ฒฐ๊ณผ๊ฐ’: ["grape", "apple", "banana", "orange"]

 

unshift() ํ•จ์ˆ˜๋Š” push() ํ•จ์ˆ˜์˜ ๋ฐ˜๋Œ€๋กœ ๋งจ์•ž์— ๋ฐฐ์—ด์˜ ์š”์†Œ๋ฅผ ์ถ”๊ฐ€ํ•˜๊ณ  ๋นˆ ํ•จ์ˆ˜๋งŒ ์‹คํ–‰ํ•˜๋ฉด ๋ฐฐ์—ด์— ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

 

5. push() vs unshift(

  • push() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์— ๋งˆ์ง€๋ง‰์— ์ƒˆ๋กœ์šด ์š”์†Œ๋ฅผ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค.
  • unshift() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์— ๋งจ์•ž์— ์ƒˆ๋กœ์šด ์š”์†Œ๋ฅผ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana"];
fruits.push("orange");
console.log(fruits);
//๊ฒฐ๊ณผ๊ฐ’: ["apple", "banana", "orange"]

fruits.unshift("grape");
console.log(fruits); 
//๊ฒฐ๊ณผ๊ฐ’: ["grape", "apple", "banana", "orange"]

 

unshift() ํ•จ์ˆ˜๋Š” push() ํ•จ์ˆ˜์˜ ๋ฐ˜๋Œ€๋กœ ๋งจ ์•ž์— ๋ฐฐ์—ด์˜ ์š”์†Œ๋ฅผ ์ถ”๊ฐ€ํ•˜๊ณ  ๋นˆ ํ•จ์ˆ˜๋งŒ ์‹คํ–‰ํ•˜๋ฉด ๋ฐฐ์—ด์— ๊ธธ์ด๋ฅผ ๋ฐ˜ํ™˜ํ•ฉ๋‹ˆ๋‹ค.

 

6. pop() vs shift()

  • pop() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์— ๋งˆ์ง€๋ง‰ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค.
  • shift() ํ•จ์ˆ˜๋Š” ๋ฐฐ์—ด์— ์ฒซ๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์ œ๊ฑฐํ•ฉ๋‹ˆ๋‹ค.

์˜ˆ์ œ

let fruits = ["apple", "banana", "orange"];

let removed = fruits.pop();
console.log(fruits); // ["apple", "banana"]
console.log(removed); // "orange"

removed = fruits.shift();
console.log(fruits); // ["banana"]
console.log(removed); // "apple"

 

shift() ํ•จ์ˆ˜ ์‹คํ–‰ํ›„ ๊ฐ’์ด “banana” ๋‚จ์•„์„œ ์ž˜๋ชป๋œ ๊ฐ’์ด๋ผ๊ณ  ์ƒ๊ฐํ•˜์‹ค ์ˆ˜ ์žˆ์ง€๋งŒ ๊นŠ์€ ๋ณต์‚ฌ์™€ ์–•์€ ๋ณต์‚ฌ์˜ ๊ฐœ๋…์ด์ง€๋งŒ ์›๋ณธ์— ๋ฐฐ์—ด์— ๊ฐ’์„ ์ˆ˜์ •ํ•˜๊ธฐ ๋•Œ๋ฌธ์— ๋ฐœ์ƒ๋˜๋Š” ํ˜„์ƒ์ž…๋‹ˆ๋‹ค.

 

๐Ÿคท‍โ™‚๏ธ ๋งˆ์ง€๋ง‰์œผ๋กœ


์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ์—์„œ ๋ฐฐ์—ด์€ ๋ฐ์ดํ„ฐ๋ฅผ ๋ฆฌ์ŠคํŠธ์—…ํ•˜๋Š” ์ž๋ฃŒ๊ตฌ์กฐ๋กœ ๋งŽ์ด ์‚ฌ์šฉ๋ฉ๋‹ˆ๋‹ค.

๊ทธ๋ž˜์„œ ์œ ์šฉํ•œ ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜๋“ค์ด ์กด์žฌํ•˜๋ฉฐ ๊ฐ€์žฅ ๋งŽ์ด ์‚ฌ์šฉ๋˜๊ณ  ์ค‘์š”ํ•œ 4๊ฐ€์ง€์˜ ๋ฐฐ์—ด ๋‚ด์žฅํ•จ์ˆ˜์— ๋Œ€ํ•ด์„œ ์•Œ์•„๋ดค์Šต๋‹ˆ๋‹ค.

push(), pop(), shift(), unshift() ๋‚ด์žฅํ•จ์ˆ˜์— ๋Œ€ํ•ด์„œ ์ฐจ์ด์ ๊ณผ ๊ฐœ๋…๊ณผ ์˜ˆ์ œ์— ๋Œ€ํ•ด์„œ ์‚ดํŽด๋ณด์•˜์Šต๋‹ˆ๋‹ค.

4๊ฐ€์ง€ ๋‚ด์žฅํ•จ์ˆ˜๋ฅผ ํ†ตํ•ด์„œ ํ•„์š”ํ•œ ์ƒํ™ฉ์— ์ ์žฌ์ ์†Œํ•˜๊ฒŒ ์‚ฌ์šฉํ•˜๋ฉด ์ข‹์„ ๊ฑฐ ๊ฐ™์Šต๋‹ˆ๋‹ค.

 

 

 


 

์žฌ๋ฐŒ๋Š” ์˜ค๋Š˜์˜ ๋ ๋ณ„ ์šด์„ธ ๋ณด๊ณ  ๊ฐ€์„ธ์š”! 

 

 

https://cometruedream.tistory.com/247

 

[React] Tailwind ํ•œ์ค„, ๋‘์ค„, ์„ธ์ค„ ํšจ๊ณผ className ์ปค์Šคํ…€

๐Ÿคท‍โ™‚๏ธ Tailwind ํ•œ์ค„, ๋‘์ค„, ์„ธ์ค„ ํšจ๊ณผํ”„๋กœ์ ํŠธ ์ง„ํ–‰์ค‘ ๋ฐฐ๋„ˆ ๋งํฌ์— URL ๊ธธ์ด๊ฐ€ ๋„ˆ๋ฌด ๊ธธ์–ด์„œ 3์ค„ ํšจ๊ณผ ์ฒ˜๋ฆฌ๋ฅผ ํ•ด์•ผ ํ–ˆ์Šต๋‹ˆ๋‹ค. React + Tailwind CSS ์…‹ํŒ…๋œ ํ”„๋กœ์ ํŠธ ์—ฌ์„œ CSS ํŒŒ์ผ & style ํƒœ๊ทธ๋ฅผ ์‚ฌ์šฉํ•˜

cometruedream.tistory.com

 

 

https://cometruedream.tistory.com/243

 

NestJS Lifecycle (์ƒ๋ช…์ฃผ๊ธฐ) ๊ฐœ๋…

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œ Nest JS ๊ฐœ๋…?Nest JS๋Š” Node JS ๊ธฐ๋ฐ˜์œผ๋กœ ํ•œ ์„œ๋ฒ„ ์–ดํ”Œ๋ฆฌ์ผ€์ด์…˜ ํ”„๋ ˆ์ž„์›Œํฌ ์ž…๋‹ˆ๋‹ค. ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋Š” ์ƒ๋‹นํžˆ ์˜ค๋žซ๋™์•ˆ Express ๊ธฐ๋ฐ˜์œผ๋กœ ์„œ๋ฒ„ ์–ดํ”Œ๋ฆฌ์ผ€์ด์…˜ ๊ฐœ๋ฐœ์—์„œ ์••๋„์ ์ธ ์ 

cometruedream.tistory.com

 

 

https://cometruedream.tistory.com/242

 

๋ฆฌ์•กํŠธ Vite Proxy ํ™œ์šฉํ•œ CORS ์˜ค๋ฅ˜ ํ•ด๊ฒฐ

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œํ”„๋ก ํŠธ์—”๋“œ ๋ฒˆ๋“ค๋Ÿฌ ๊ฐœ๋…๊ณผ webpack vs vite ๋น„๊ต์— ๋Œ€ํ•ด์„œ ๊ณต๋ถ€๋ฅผ ํ•˜๊ณ  ๊ธ€์„ ๋ณด์‹œ๋ฉด ๋” ๋งŽ์€ ๋„์›€์ด ๋ฉ๋‹ˆ๋‹ค^^ํ”„๋ก ํŠธ์—”๋“œ ๊ฐœ๋ฐœ์„ ์œ„ํ•œ ๋ฒˆ๋“ค๋Ÿฌ ๊ฐœ๋…๊ณผ webpack vs vite ๋น„๊ตhttps://comet

cometruedream.tistory.com

 

 

https://cometruedream.tistory.com/241

 

React ํด๋”๊ตฌ์กฐ FSD ๊ธฐ๋Šฅ ๋ถ„ํ™œ ์„ค๊ณ„ ์•„ํ‚คํ…์ฒ˜

๐Ÿคท‍โ™‚๏ธ ๋ณธ๋ก ์— ์•ž์„œํ”„๋กœ์ ํŠธ๋ฅผ ์‹œ์ž‘ํ•˜๊ธฐ์— ์•ž์„œ ํด๋” ๊ตฌ์กฐ, ์„ค๊ณ„์— ๋Œ€ํ•œ ์•„ํ‚คํ…์ฒ˜๋ฅผ ๋งŒ๋“œ๋Š” ๊ฒƒ์€ ์ƒ๋‹นํžˆ ์–ด๋ ต๋‹ค. ์ด๋ฒˆ ํ”„๋กœ์ ํŠธ์— React FSD ํด๋”๊ตฌ์กฐ ์•„ํ‚คํ…์ฒ˜๋ฅผ ์„ค๊ณ„ํ•  ์˜ˆ์ •์ด๋ผ์„œ FSD ์•„ํ‚คํ…

cometruedream.tistory.com

 

 

https://cometruedream.tistory.com/244

 

์‰ฝ๊ฒŒ ์ดํ•ดํ•˜๊ณ  ์‚ฌ์šฉํ• ์ˆ˜ ์žˆ๋Š” Prisma ๋ช…๋ น์–ด ์ •๋ฆฌ

๐Ÿคท‍โ™‚๏ธ Prisma ๋ช…๋ น์–ด ๋ณธ๋ก ์— ์•ž์„œ Prisma๋ž€?Nest JS ํ”„๋ ˆ์ž„์›Œํฌ์™€ Prisma ORM์„ ํ™œ์šฉํ•ด์„œ ํ”„๋กœ์ ํŠธ๋ฅผ ์ง„ํ–‰ํ•˜๋ฉด์„œ Prisma๋Š” Node JS ๊ธฐ๋ฐ˜์— ํ”„๋ ˆ์ž„์›Œํฌ/๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ์™€ ์ƒํ˜ธ์ž‘์šฉ์ด ์ž˜๋˜๋ฉฐ Prisma + DB ์—ฐ๋™์œผ

cometruedream.tistory.com