묻고 답해요
164만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결처음 배우는 리액트 네이티브
header Button 질문입니다!
Stack Navigation-버튼 수정 부분에서 headerLeft와 headerRight로 버튼을 만드는 부분은 알겠는데, 혹시 header의 오른쪽에 버튼을 두 개 만드는 방법은 없을까요?? 따로 버튼 컴포넌트를 만들어서 넣으면 마진값을 주거나 할 때 기기 크기마다 차이가 날까봐 headerRight를 쓰는 방법과 비슷하게 버튼을 생성하고 싶습니다.. 구글링을 해봐도 headerLeft와 headerRight 두 개를 만드는 것밖에 찾지 못해 질문드립니다ㅜㅜ
-
미해결따라하며 배우는 노드, 리액트 시리즈 - 쇼핑몰 사이트 만들기[전체 리뉴얼]
이 오류는 어디서 발생하는건가요?
index.js:1 Warning: Encountered two children with the same key, `1`. Keys should be unique so that components maintain their identity across updates. Non-unique keys may cause children to be duplicated and/or omitted — the behavior is unsupported and could change in a future version. in select (at UploadProductPage.js:68) in form (created by Context.Consumer) in Form (at UploadProductPage.js:49) in div (at UploadProductPage.js:43) in UploadProductPage (at auth.js:38) in AuthenticationCheck (created by Context.Consumer) in Route (at App.js:24) in Switch (at App.js:20) in div (at App.js:19) in Suspense (at App.js:17) in App (at src/index.js:29) in Router (created by BrowserRouter) in BrowserRouter (at src/index.js:28) in Provider (at src/index.js:21)
-
미해결작정하고 장고! Django로 Pinterest 따라만들기 : 바닥부터 배포까지
action과 {{ requset.path }}에 대해 여쭙고 싶습니다..!
찾아보니 action 속성은 <form> 태그에 입력된 내용을 처리하는 서버 프로그램의 URI를 지정하는 역할을 한다. 라고 하고 선생님께서는 16강에서, 요청하는 url 주소라고 하셨는데.. 제가 이해하기로는 제가 입력한 정보들을 form에 담아 어디로 보낼 것인가를 action에서 정의한다고 이해했는데 맞는건가요...? 예를들어, create에서는 form에 회원가입 정보를 담아서 action = accountapp/create에 보내는 것처럼요. 근데 login.html에서는 왜 action이 공란인지 여쭤봐도 될까요 ㅠㅠ 진짜 잘 이해가 안가네요... (3:58초) 마지막으로.. next를 사용하는 것까진..대략적으로 알겠는데, (8분 38초) {{ request.path }}가 붙는 이유는 무엇인가요? 매번 이런 질문...답변해주시는 거 정말 감사합니다 ㅜ 이런 강의는 세일할 때 말고 정가로 샀어야하는데ㅣ..ㅜㅡㅜ
-
미해결작정하고 장고! Django로 Pinterest 따라만들기 : 바닥부터 배포까지
8:17초 질문드립니다.
hello_world_list = HelloWorld.objects.all() 을 지우셨는데.. return HttpResponseRedirec(생략) 이므로 지워도 영향은 안 받겟지만...hello_world.html 에 아직 {% if hello_world_list %} {% for hello_world in hello_world_list %} <h4> {{ hello_world.text }} </h4> {% endfor %}{% endif %} 이 있으므로 지우면 안되지 않나요...? 근데 지우고 실행해보니 또 잘 되더라구요. 근데 제가 생각으로는 Redirect돼서 hello_world.html이 실행되는데 hello_world_list가 없으면 html이 실행이 안되므로 {{ hello_world.text }}도 실행이 안될텐데.. 왜 되는 걸까요...?
-
미해결실전! 스프링 데이터 JPA
Distinct
안녕하세요 영한님 강의 너무 잘보고있습니다. Distinct 쿼리를 한번 만들어 보았는데요 public interface MemberRepository extends JpaRepository<Member,Long> { List<Member> findDistinctByUsername(String userName); } ========================= //테스트 코드 @Test public void findDistinctByUsername(){ Member m1 = new Member("AAA", 10); Member m2 = new Member("AAA", 20); memberRepository.save(m1); memberRepository.save(m2); List<Member> findDistinctByUsername = memberRepository.findDistinctByUsername("AAA"); } ================================== 실행 결과 Hibernate: select distinct member0_.member_id as member_i1_0_, member0_.age as age2_0_, member0_.team_id as team_id4_0_, member0_.username as username3_0_ from member member0_ where member0_.username=? --------------------------------------------- 제가 궁금한건 결국 마지막엔 Member 의 필드를 모두 조회합니다. 그런데 Id 의 값은 중복이 될수 없으니 이 쿼리는 Member 엔티티를 모두 조회하는거랑 같습니다. Id를 요구하지않는 테이블에서만 이런 쿼리 메소드(distinct ) 를 사용하는건가요 ??
-
미해결2022 30분 요약 강좌 시즌 1 : HTML, CSS, Linux, Bootstrap, Python, JS, jQuery&Ajax
html의 input
<input type="checkbox" name="언어" id="python" value="Python" /> 여기서 value의 역할은 무엇인가요?
-
미해결2022 30분 요약 강좌 시즌 1 : HTML, CSS, Linux, Bootstrap, Python, JS, jQuery&Ajax
HTML - input
- 학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요! - 먼저 유사한 질문이 있었는지 검색해보세요. - 서로 예의를 지키며 존중하는 문화를 만들어가요. - 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요. html 태그 중에 <input type="checkbox" name="언어" id="python" value="Python" /> 일때, value의 역할은 무엇인가요?
-
미해결따라하며 배우는 TDD 개발 [2023.11 업데이트]
선생님 안녕하세요
firstProduct의 데이터를 먼저 가져온다음에서야 GET /api/product/:productId 통합테스트가 통과가 되는데요 그럼 모든 테스트의 순서는 파일의 처음부터 파일의 끝 순으로 위아래로 차례로 실행이되는건가요 ??? 제가 자바 Junit할때는 랜덤으로 실행이됬던것같아서 Order라는 어노테이션을 따로 붙혀줬었던걸로 기억을해서요! 물론 자바는 이 강의와 전혀 무관한 내용인데 예를 들어서 죄송합니다 ㅠㅠ
-
미해결탄탄한 백엔드 NestJS, 기초부터 심화까지
npm start 혹은 npm run start를 치면 자꾸 아래와 같은 오류가 나타납니다.
src/app.module.ts:1:24 - error TS2307: Cannot find module '@nestjs/common' or its corresponding type declarations. 1 import { Module } from '@nestjs/common'; 자꾸 이런오류가 나오고서버가 실행되질않습니다. 이거 해결하려면 어떻게 해줘야하는것일까요 ?
-
미해결[리뉴얼] React로 NodeBird SNS 만들기
프론트 서버에서 빌드시 react-dom이 없어서 빌드 실패가 뜨는데...
Failed to compile. ModuleNotFoundError: Module not found: Error: Can't resolve 'react-dom' in '/home/ubuntu/react-nodebird/front/node_modules/next/dist/client' 이렇게 뜨길래 프론트 서버에서 npm i react-dom 하고 빌드 하니까 되긴 됐는데 괜찮겠죠? 로컬에 먼저 npm i react-dom하고 깃헙에 푸시하고 aws에서 풀 받아서 하려했는데 로컬에서 npm i react-dom하니까 이미 next 내장인가보더라고요. 로컬과 서버가 싱크 안 맞아도 괜찮겠죠..?
-
미해결[리뉴얼] React로 NodeBird SNS 만들기
현재 도메인에 나오는 post 삭제하는 방법 질문입니다.
제로초님 안녕하세요 친절한 설명덕분에 감사하게 강의를 성공적으로 따라갈 수 있었습니다배포한 이후에 post들을 싹 삭제하고 싶으면 혹시 어떻게 삭제해야하나요??aws에 들어가서 어떻게 삭제해야하는지 혹시 여쭤봐도될까요?기존에 로컬에서 진행할때는 mySql때는 Workbench에 들어가서 Post테이블 싹 지우면 됐는데싹 지우고 싶은이유는 삭제버튼을 눌러서 삭제하면 해당 id는 빈상태로 나오기 때문입니다.또한 제가 아닌 다른사람이 이상한글을 썼을때 삭제를 하기 위해서 다른사람이 쓴 글도 삭제하고싶기때문입니다.
-
미해결it 취업을 위한 알고리즘 문제풀이 입문 (with C/C++) : 코딩테스트 대비
문제 접근법에 관해 질문 드립니다.
안녕하세요 선생님 강의 잘 듣고있습니다. 본 문제도 동적 프로그래밍 알고리즘이 적용된 문제라고 봐도 되나요?
-
미해결Slack 클론 코딩[실시간 채팅 with React]
npm run build 에러
제로초님, 안녕하세요! npm run build 하고 index.html 라이브 서버 켜봤는데 화면에 아무것도 나오지 않습니다..! dist 폴더와 App.js 파일은 잘 생겼구요 아래는 에러 내용입니다. 제로초님의 소스코드를 살펴보니 package.json에 emotion/babel-plugin은 설치되어 있지 않았는데ㅜㅜ 그걸 설치하면 해결되는걸까요? $ npm run build > client@1.0.0 build C:\Users\user\Desktop\coding\sleact\client > cross-env TS_NODE_PROJECT="tsconfig-for-webpack-config.json" webpack asset app.js 4.28 KiB [emitted] (name: app) ./client.tsx 39 bytes [built] [code generated] [1 error] ERROR in ./client.tsx Module build failed (from ./node_modules/babel-loader/lib/index.js): Error: Cannot find module '@emotion/babel-plugin' Require stack: - C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\files\plugins.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\files\index.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\index.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\babel-loader\lib\index.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\loader-runner\lib\loadLoader.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\loader-runner\lib\LoaderRunner.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack\lib\NormalModuleFactory.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack\lib\Compiler.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack\lib\webpack.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack\lib\index.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack-cli\lib\webpack-cli.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack-cli\lib\bootstrap.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack-cli\bin\cli.js - C:\Users\user\Desktop\coding\sleact\client\node_modules\webpack\bin\webpack.js at Function.Module._resolveFilename (internal/modules/cjs/loader.js:965:15) at resolve (C:\Users\user\Desktop\coding\sleact\client\node_modules\v8-compile-cache\v8-compile-cache.js:164:23) at resolveStandardizedName (C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\files\plugins.js:111:7) at resolvePlugin (C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\files\plugins.js:55:10) at loadPlugin (C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\files\plugins.js:63:20) at loadPlugin.next (<anonymous>) at createDescriptor (C:\Users\user\Desktop\coding\sleact\client\node_modules\@babel\core\lib\config\config-descriptors.js:187:16) at createDescriptor.next (<anonymous>) at step (C:\Users\user\Desktop\coding\sleact\client\node_modules\gensync\index.js:261:32) at evaluateAsync (C:\Users\user\Desktop\coding\sleact\client\node_modules\gensync\index.js:291:5) sleact (webpack 5.51.1) compiled with 1 error in 1475 ms npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! client@1.0.0 build: `cross-env TS_NODE_PROJECT="tsconfig-for-webpack-config.json" webpack` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the client@1.0.0 build 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! C:\Users\user\AppData\Roaming\npm-cache\_logs\2021-08-24T16_04_56_594Z-debug.log
-
미해결[파이토치] 실전 인공지능으로 이어지는 딥러닝 - 기초부터 논문 구현까지
cam모델 구축 질문드립니다.
1.data, label = trainset[img_sample] # 이미지 한 장과 라벨 불러오기 라고 설명 되 있는데 [img_sample]이 어디서 나온건지 , 무슨역할을 하는건지 모르겠습니다.... ㅜ 2. hook을 통해 feature map을 가져온다고 하셨는데 model.layer4[1].bn2.register_forward_hook(get_activation('final')) 여기서 'final'은 임의로 name을 정하신건가요? 3. data.unsqueeze_(0) 차원을 늘린 이유가 궁굼합니다
-
미해결[초급편] 안드로이드 커뮤니티 앱 만들기(Android Kotlin)
안녕하세요 개발자님
개발자님이 만드신 어플에서 꿀팁 부분 게시판을 눌렀을때 웹으로 이동하는게 아닌 다른방식인데 밑에 그림처럼 이부분의 강의 내용은 어디있는지 알수있을까요?
-
미해결따라하며 배우는 노드, 리액트 시리즈 - 영화 사이트 만들기
NavBar 질문
안녕하세요 강사님! 다름이 아니라 boiler-plate 클론 이후 Movie-App 만들기 까지 완료하였는데요, NavBar 의 메인 로고 부분의 이미지를 변경해보고 싶어서 다른 이미지를 삽입하고자 하는데 도대체 어디 부분을 건드려야 할지 잘 모르겠습니다!!기존에 movie-app-ko 파일에는 components파일에 assets/images 라는 폴더가 있고, 내부에 movieapp 의 이미지가 저장되어있는데 이 저장된 이미지를 어느부분에서 사용하시고 있는지 전혀 모르겠습니다...!! img src 를 통해서 새로운 이미지를 삽입해보려고 하면 계속 오류가 생겨서... 답변 부탁드립니다!!
-
미해결취미로 해킹#1(OverTheWire - Bandit)
bandit16 -> 17
ssh -i /tmp/new/rsakey bandit17@localhost 를 입력하면 Enter passphrase for key '/tmp/new/rsakey': 라는 문구가 뜹니다. 어떻게 해야하나요?
-
미해결홍정모의 따라하며 배우는 C++
resize() 이전에 질문드렸던 내용 code 올려드립니다.
#include <iostream> #include <vector> #include <array> #include <initializer_list> class IntArray { int m_length = 0; int* m_data = nullptr; public: IntArray(int length_in) : m_length(length_in) { m_data = new int[m_length]; } IntArray(const std::initializer_list<int>& list) : IntArray(list.size()) { initialize(list); } ~IntArray() { delete[] m_data; } void initialize(const std::initializer_list<int>& list) { int count = 0; for (auto& ele : list) { m_data[count] = ele; ++count; } } void reset() { m_length = 0; if (m_data != nullptr) { delete[] m_data; m_data = nullptr; } } void resize(const int& size) { int pre_length = m_length; m_length = size; if (m_data != nullptr) { int* temp = new int[pre_length]; for (int i = 0; i < pre_length; i++) temp[i] = m_data[i]; delete[] m_data; m_data = new int[m_length]; //for (int i = 0; i < m_length; i++) for (int i = 0; i < pre_length; i++) { m_data[i] = temp[i]; //if (i <= pre_length) m_data[i] = temp[i]; //else m_data[i] = 0; if (i == size - 1) break; //size가 작아질 경우 } delete[] temp; } else m_data = new int[m_length]; } void insertBefore(const int& value, const int& ix) { resize(m_length + 1); for (int i = 0; i < m_length; i++) { if (m_data[i] == ix) { for (int j = m_length - 1; j > i; j--) m_data[j + 1] = m_data[j]; m_data[i+1] = value; break; } } } void remove(const int& ix) { for (int i = 0; i < m_length; i++) { if (m_data[i] == ix) { for (int j = i; j < m_length - 1; j++) m_data[j] = m_data[j + 1]; resize(m_length - 1); break; } } } void push_back(const int& value) { resize(m_length + 1); m_data[m_length -1] = value; } friend std::ostream& operator << (std::ostream& out, const IntArray& arr) { for (int i = 0; i < arr.m_length; i++) out << arr.m_data[i] << " "; return out; } }; int main() { IntArray my_arr{ 1,3,5,7,9 }; std::cout << my_arr << std::endl; my_arr.insertBefore(10,1); std::cout << my_arr << std::endl; my_arr.remove(3); std::cout << my_arr << std::endl; my_arr.push_back(13); std::cout << my_arr << std::endl; std::vector<int> int_vec; std::array<int, 10> int_arr; return 0; } 웨에 코드입니다 사이즈를 크게 바꾸면서 빈자리에는 초기화를 안해주었는데 그때문에 문제가 생기는게 아닐까 했지만 나이라고 하셔서 코드올려드립니다. 주석처리 된대로 바꾸면 잘 동작합니다 ㅠ 아래 인터넷 컴파일러 주소 올려드립니다. http://tpcg.io/yjKoNFmS
-
해결됨풀스택 리액트 토이프로젝트 - REST, GraphQL (for FE개발자)
onupdate 매개변수
onupdate 함수의 매개변수를 (id, text) 로 넣어주었더니! 수정 버튼을 클릭 했을 때 내용이 바뀌지 않더라구요 그래서 혹시나해서 매개변수를 (text, id) 로 변경했더니 수정 기능이 제대로 작동 했습니다. 매개변수 순서가 바뀌면 문제가 있는걸까요??
-
해결됨스프링 입문 - 코드로 배우는 스프링 부트, 웹 MVC, DB 접근 기술
h2.bat 실행 관련 질문입니다
안녕하세요,, bin 에서 h2.bat를 실행하거나 cmd에서 h2.bat 후 엔터를 해도 서버모드로 접속이 안됩니다,, 어떻게 해야 할까요..?