안녕하세요. 쿠키 관련 질문이 있습니다. front에서 axios로 보낼 때 withcredentials: true 를 해주고 backend에서도 cors에서 credentials : true를 해주었기 때문에 로컬에서 프론트와 백엔드를 같이 돌릴 경우에는 쿠키 공유 문제가 없습니다. 그런데 백엔드를 aws EC2에 두고 프론트 엔드를 로컬에서 돌릴 경우 쿠키가 공유되지 않습니다. 원인은 samesite 정책 때문이고 해결하려면 backend에서 쿠키를 보낼 때 samesite=none과 secure:true를 같이 적용해줘야 한다는 걸 알았습니다. 이를 해결하려면 결국 https 적용을 위해 nginx로 프록시를 만들어 줘야 하는데 다른 방법이 있을까요? 간단한 방법은 로컬에서 계속 테스트 하다가 배포관련 수업에서 하는 것 처럼 도메인을 같이 등록하면 되긴 하지만 이런 경우에도 해결하는 방법이 있는지 궁금합니다.
키보드 조작하는 부분까지 강의를 따라 만들어둔 상태입니다. (스코어 부분 시작 직전까지, 약 37분 45초까지) * 키보드 동작을 넣기전에는 4x4 셀을 그린 후 두 곳에 랜덤하게 숫자2를 표현하였습니다. * 키보드 동작까지 완료 후 4x4 셀을 그린 후 아무런 타일이 생성되지 않고 있습니다. 키보드 동작시에 에러도 없습니다. 강의 진행 중 아무런 에러도 발생하지 않고 코드를 역추적해가며 살펴봐도 어디 부분에서 잘못을 했는지 찾아지지가 않습니다 ㅠㅠ 도움이 필요합니다! * 깃에 올려둔 코드 주소입니다( https://github.com/Doha-Dev/game2048.git )
안녕하세요 제로초님 강의 잘 듣고 있습니다. 이번 강의에서 컴포넌트 분리하는 방법을 배웠는데요. 혹시 함수 부분도 기능별로 분리할 수 있는지 궁금합니다. 또 리액트에서 스타일 작업을 할때는 기존에 html에 css를 link 걸었던 방식대로 하면 될까요? 너무 초보적인 질문인가 싶긴 하지만 궁금해서 질문 남겨봅니다ㅎㅎ
(node:17608) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at C:\Users\oksos\Desktop\study\PTE\loginWeb\client\node_modules\postcss-safe-parser\node_modules\postcss\package.json. Update this package.json to use a subpath pattern like "./*". (Use `node --trace-deprecation ...` to show where the warning was created) createProxyMiddleware is not a function
간단한 궁금증입니다.. map()과 forEach()의 세세한 차이점은 검색을 해봤는데 map메소드가 보통 성능 면에서도 더 빠르고 기존의 데이터를 변형시키지 않고 새로운 배열을 반환하기 때문에 기존 데이터가 필요한 경우에도 쓸 수 있을 것 같다는 생각이 들었습니다. 강사님은 각각 어떤 경우에 map()과 forEach()를 사용하시는지 여쭤보고 싶습니다!
reducers 폴더의 index파일의 rootReducer함수에서 defalut: return state 들어가는이유 설명해주실때 액션타입해서 그 다음상태 만들어주는것을 처리해주는대 리듀서 초기화할때 또 rootReducer함수가 실행이되는대 그때defalut: return state이 부분이 없으면 리턴값이 undefined된다 이렇게 설명해주셨는대 리듀서가 왜 초기화되는지 이유가 궁금합니다!
되게 여러번 따라 했는데, 새로고침 하고난 후 로그인이 유지가 되지 않습니다..ㅠㅠ authSaga 속의 함수들이 제대로 작동하지 않는것 같습니다.... authoSaga속 함수를 호출하는 시작이 어딘지 순서 또한 잘 파악되지 않습니다..ㅠ 계속 401에러가 뜹니다. ㅠㅠ
element.style { } user agent stylesheet body { display : block ; margin : 8px ; } margin 8 8 border ‒ ‒ padding ‒ ‒ 1113 × 1247 ‒ ‒ ‒ ‒ 8 8 Console What's New Issues top Default levels Some messages have been moved to the Issues panel. View issues index.html:95 Live reload enabled. babel.min.js:1 You are using the in-browser Babel transformer. Be sure to precompile your scripts for production - https://babeljs.io/docs/setup/ react-dom.development.js:82 Warning: Cannot update during an existing state transition (such as within `render`). Render methods should be a pure function of props and state. in LikeButton in div react-dom.development.js:19662 The above error occurred in the <LikeButton> component: in LikeButton in div Consider adding an error boundary to your tree to customize error handling behavior. Visit https://fb.me/react-error-boundaries to learn more about error boundaries. react-dom.development.js:11237 Uncaught Error: Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops. at checkForNestedUpdates ( react-dom.development.js:23228 ) at scheduleUpdateOnFiber ( react-dom.development.js:21299 ) at Object.enqueueSetState ( react-dom.development.js:12774 ) at LikeButton.Component.setState ( react.development.js:557 ) at LikeButton.render (<anonymous>:49:23) at finishClassComponent ( react-dom.development.js:17295 ) at updateClassComponent ( react-dom.development.js:17245 ) at beginWork ( react-dom.development.js:18755 ) at beginWork$1 ( react-dom.development.js:23314 ) at performUnitOfWork ( react-dom.development.js:22289 )
- Postman으로 email, PW를 보내며 '비밀번호가 틀렸습니다' 가 Response로 돌아오면서 아래 에러가 나옵니다... 비번은 분명 맞는데 이런 에러가 나옵니다ㅜ 혹시 이유를 알 있나요? - 좀 길지만 전체 코드 복붙했습니다. 감사합니다! CODE ERROR _http_outgoing.js:558 throw new ERR_HTTP_HEADERS_SENT('set'); ^ Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client at ServerResponse.setHeader (_http_outgoing.js:558:11) at ServerResponse.header (/Users/user/VS Code/project_with_NodeJS/boiler-plate/node_modules/express/lib/response.js:771:10) at ServerResponse.send (/Users/user/VS Code/project_with_NodeJS/boiler-plate/node_modules/express/lib/response.js:170:12) at ServerResponse.json (/Users/user/VS Code/project_with_NodeJS/boiler-plate/node_modules/express/lib/response.js:267:15) at /Users/user/VS Code/project_with_NodeJS/boiler-plate/index.js:48:20 at /Users/user/VS Code/project_with_NodeJS/boiler-plate/models/user.js:62:9 at /Users/user/VS Code/project_with_NodeJS/boiler-plate/node_modules/bcrypt/bcrypt.js:210:13 at processTicksAndRejections (internal/process/task_queues.js:75:11) { code: 'ERR_HTTP_HEADERS_SENT' } npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! boiler-late@1.0.0 start: `node index.js` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the boiler-late@1.0.0 start script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /Users/user/.npm/_logs/2020-12-28T03_02_38_926Z-debug.log
안녕하세요, 수업 정말 감사합니다~! 오타인것 같아서, 선생님 깃허브도 보고 비교하면서 했는데, 여전히 고쳐지지가 않아서, 질문드려요 ㅠ console로 찍었을때, user값이 이 값으로 나오는데, 들어노는게 문제인지 어느 부분이 잘못되었을까요? email값이 null이네요.. ㅠ { role: 0, _id: 5fcf43430591df2796372b6c } https://github.com/cocoball200/react-project 위에 제 깃허브에서 commit 메세지에 error부분들을 고쳤습니다! 항상 감사합니다~!