본문 바로가기

과제기록4

[페어]statesairline-server //app.js부분 const flightRouter = require('./router/flightRouter'); 저부분 따라서 flightRouter.js파일로 가면 //flightRouter.js부분 const { findAll, findById, update } = require('../controller/flightController'); 저렇게 flightRouter와 flightController는 연결이 되고 flightController에 가면 findAll, findById, update가 있다 일단 이렇게 쭉 연결이 되고 //app.js app.use('/flight', flightRouter); app.use('/book', bookRouter); app.use('/airport'.. 2023. 2. 8.
[페어] statesairline-client Search.js import { useState } from 'react'; function Search({onSearch}) { const [textDestination, setTextDestination] = useState(''); const handleChange = (e) => { setTextDestination(e.target.value.toUpperCase()); }; const handleKeyPress = (e) => { if (e.type === 'keypress' && e.code === 'Enter') { handleSearchClick(); } }; const handleSearchClick = () => { console.log('검색 버튼을 누르거나, 엔터를 치면 searc.. 2023. 2. 3.
[페어] beesbeesbees super, extends이용하기 ★★★ Grub.js class Grub { constructor(){ this.age= 0; this.color= 'pink'; this.food= 'jelly'; } eat(){ return 'Mmmmmmmmm jelly' ; } } module.exports = Grub; bee.js const Grub = require('./Grub'); class Bee extends Grub{ constructor(){ //Grub에 food랑 eat있어서 따로 안써도된다. super(); this.age= 5; this.color= 'yellow'; this.job= `Keep on growing`; } } module.exports = Bee; HoneyMakerBee.j.. 2023. 1. 28.
[project] 나만의 아고라스테이츠만들기 [Solo project] 일단 기본적인것까지만 구현하도록 했다. (디스커션까지 추가) # CSS 맨처음 이거 일단 넣자. 그리고 각구역 나눠서 border만들자! *{ box-sizing: border-box; margin: 0; padding: 0; } body { display: flex; justify-content: center; align-items: center; } #완성본 (CSS) * { box-sizing: border-box; margin: 0; padding: 0; } body{ display: flex; justify-content: center; align-items: center; } main{ background-color: #aacdbe; } h1 { color: #f0e.. 2023. 1. 10.