묻고 답해요
164만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결Vue.js 중급 강좌 - 웹앱 제작으로 배워보는 Vue.js, ES6, Vuex
TS Lint 설치 질문 & 권한 요청드립니다.
안녕하세요. Vue 기초강좌를 듣고나서 중급강좌로 넘어온 수강생입니다. 강의 해주신 것 정말정말 완전 잘 듣고 있다고 말씀드리고 싶었습니다~ 질문 VS Code에서 TSLint 설치를 하려고 확장탭에서 검색을 하니 설치는 가능한 상태이지만,[이 확장은 더이상 유지 관리되지 않으므로 더 이상 사용되지 않습니다.] 라고 뜨는데, 혹시 TSLint로 검색했을 때에 같이 드는 다른 중에서 대신 설치할 수 있는 것이 있는지 여쭤봅니다.<TS Lint 검색시 같이 나오는 리스트>- TSLint / TSLint Vue / TSLint Snippets / TSLint Vue-TSX※Vue+TypeScript 강좌도 같이 듣고 있어서 그 강좌에 나오는 환경설정은 되어 있는데, 그거랑은 별도로 TSLint를 설치해야 하는지 여쭤봅니다. Github 권한 요청 인프런 아이디 : ehddndnjs@hanmail.net 인프런 이메일 : ehddndnjs@hanmail.net 깃헙 아이디 : ehddndnjs@hanmail.net 깃헙 Username : sumin33
-
미해결Nuxt.js 시작하기
혹시 nuxt에도 swr과같은 기능을하는것이 있을까요?
같은 데이터를 쓰는경우 여러 컴포넌트에서 똑같은 api를 호출할텐데 swr과 같이 여러곳에서 호출을해도 캐싱을해서 똑같은 api호출시 1번만호출하게끔 할수있나요 ?
-
미해결
Why is Scubanautic the Best Place to try Scuba Diving in Mallorca?
If you're looking for a place to try it out in Diving in Mallorca, Scubanautic is the place for you. They offer scuba diving Mallorca courses of varying lengths, including one-day classes for beginners who want to take things slowly and more challenging courses for those who are ready to take their skills to the next level. They have instructors from all over the world who speak English and other languages. And they make sure every course is customized to suit your needs so that you can be assured of a great experience during your time with them.
-
미해결스프링 MVC 1편 - 백엔드 웹 개발 핵심 기술
프로젝트 설정저장
강의 내용과는 직접적인 연관은 없지만 프로젝트를 신규로 만들때마다 어노테이션 프로세싱체크, 빌드 설정에서 인텔리제이로 빌드, 등을 매번다시 설정해야하나요?
-
미해결
What is the Best Catalytic Converter Recycling Australia Company?
Are you looking for the best catalytic converter recycling Australia company? If so, then look no further than QLD Catalytic Converters. They offer a lifetime warranty on their catalytic converters because They believe that when it comes to your vehicle, you deserve nothing but the best. They don't stop at being the best. And also offer same-day shipping and affordable pricing so that your wallet doesn't suffer either. Call now!
-
미해결자바(Java) 알고리즘 문제풀이 입문: 코딩테스트 대비
while문 안 질문있습니다.
while(sum >= m) 으로 작성해주셨는데요 while(sum > m)으로 해도 반복 횟수는 똑같은거 같은데 맞나요? 그냥 궁금해서.. 확인차 글 남깁니다 !
-
미해결스프링 MVC 2편 - 백엔드 웹 개발 활용 기술
질문이 있습니다!
안녕하세요. 사실 선생님 강의 시리즈 전체 다 들은지 꽤 됐습니다. 배운 걸 바탕으로 개인 사이드 프로젝트를 진행중에 있습니다. 저의 경우 Spring Security 와 JWT를 함께 써서 로그인 및 인증인가를 처리하고 있습니다. 지금까지 한 방식은 다음과 같습니다. 만약 사용자 정보를 삭제하는 요청이 수행되기 위해서는 먼저 컨트롤러에서 요청을 받고, 서비스 내부에 기능을 수행하고 리턴을 해주는데, 서비스 내부 메소드에서 현재 접속중인 유저의 세션을 Authentication auth = SecurityContextHolder.getContext().getAuthentication() 을 이용해서 세션 정보를 받아주고, 메소드의 들어온 userId 가 현재 로그인 된 유저의 userId 가 같다면 삭제되게 로직을 만들어서 작동도 잘 됩니다. 다만, 생각을 해보니 Service 에서는 보통 도메인의 비즈니스 로직이 들어가야하는데 저의 경우는 Spring Security를 여기에 의존해서 쓰고 있어서 문제가 될 수 있다고 생각해서 한 가지 의문이 들어서 질문 드립니다. 선생님은 보통 실무에서 인증인가를 어디서 처리하시나요? 서비스 안에서 Security를 의존하는 방식이 문제가 될까요? 문제가 된다면 다음과 같은 방식으로 해결하고자 하는데 어떤지 조언 부탁드리겠습니다. 1. 서비스 로직 진입 전 필터계층을 aop로 두고, 해당 API, 즉 컨트롤러에 진입할 때 필터 계층에서 미리 걸러주는 방법 2. 컨트롤러에서 인증에 필요한 정보를 미리 뽑아서 서비스 메소드 파라미터로 전달해주기 감사합니다 ^^
-
미해결배달앱 클론코딩 [with React Native]
회원가입 서버 연동 진행 중에 무한 로딩 현상이 발생합니다..
- 학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요! - 먼저 유사한 질문이 있었는지 검색해보세요. - 서로 예의를 지키며 존중하는 문화를 만들어가요. - 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요. 주소가 잘못된 것 같기도 한데.. 메트로 서버에 주소까지는 콘솔 잘 찍히구요 빌드 후안드로이드 스튜디오에서 10.0.2.2:3105 주소가 나오는 것 확인 했습니다.. public static final String API_URL = "http://10.0.2.2:3105"; 어떤 문제 인지 알 수 있을까요..? 아래는 SignUp 코드 전문 입니다 import React, {useCallback, useRef, useState} from 'react'; import { ActivityIndicator, Alert, KeyboardAvoidingView, Platform, Pressable, StyleSheet, Text, TextInput, View, } from 'react-native'; import {NativeStackScreenProps} from '@react-navigation/native-stack'; import {RootStackParamList} from '../../App'; import DismissKeyboardView from '../components/DismissKeyboardView'; import axios, { AxiosError } from 'axios'; import Config from 'react-native-config'; type SignUpScreenProps = NativeStackScreenProps<RootStackParamList, 'SignUp'>; function SignUp({navigation}: SignUpScreenProps) { const [loading, setLoading] = useState(false); const [email, setEmail] = useState(''); const [name, setName] = useState(''); const [password, setPassword] = useState(''); const emailRef = useRef<TextInput | null>(null); const nameRef = useRef<TextInput | null>(null); const passwordRef = useRef<TextInput | null>(null); const onChangeEmail = useCallback(text => { setEmail(text.trim()); }, []); const onChangeName = useCallback(text => { setName(text.trim()); }, []); const onChangePassword = useCallback(text => { setPassword(text.trim()); }, []); const onSubmit = useCallback( async () => { if (loading) { return; } //로딩 중인데 버튼 누를 경우 요청 XX if (!email || !email.trim()) { return Alert.alert('알림', '이메일을 입력해주세요.'); } if (!name || !name.trim()) { return Alert.alert('알림', '이름을 입력해주세요.'); } if (!password || !password.trim()) { return Alert.alert('알림', '비밀번호를 입력해주세요.'); } if ( //이메일을 검사하는 정규 표현식 !/^(([^<>()\[\]\.,;:\s@\"]+(\.[^<>()\[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/.test( email, ) ) { return Alert.alert('알림', '올바른 이메일 주소가 아닙니다.'); } if (!/^(?=.*[A-Za-z])(?=.*[0-9])(?=.*[$@^!%*#?&]).{8,50}$/.test(password)) { return Alert.alert( '알림', '비밀번호는 영문,숫자,특수문자($@^!%*#?&)를 모두 포함하여 8자 이상 입력해야합니다.', ); } console.log(email, name, password); //axios 사용해서 서버로 보내주기, async await 문법 쓸거임 try{ setLoading(true); console.log(Config.API_URL); //Http 메서드 : get, put, patch, post, delete, head, options 등 (get, delete는 data를 못넣음) const response = await axios.post(`${Config.API_URL}/user`, { email, name, password, });// 네이버에 내 아이피 치면 내 주소 나옴 console.log(response.data); Alert.alert('알림', '회원가입 되었습니다.'); navigation.navigate('SignIn'); } catch (error) { // 요청 실패 시 const errorResponse = (error as AxiosError).response; //타입 적용한 변수 console.error(errorResponse); if(errorResponse) { Alert.alert(errorResponse.data.message); } } finally { //try든 catch든 항상 최종적으로 finally 구문 실행함 setLoading(false); } }, [loading, navigation, email, name, password]); const canGoNext = email && name && password; return ( <KeyboardAvoidingView behavior = "position"> <View style={styles.inputWrapper}> <Text style={styles.label}>이메일</Text> <TextInput style={styles.textInput} onChangeText={onChangeEmail} placeholder="이메일을 입력해주세요" placeholderTextColor="#666" textContentType="emailAddress" value={email} returnKeyType="next" clearButtonMode="while-editing" ref={emailRef} onSubmitEditing={() => nameRef.current?.focus()} blurOnSubmit={false} /> </View> <View style={styles.inputWrapper}> <Text style={styles.label}>이름</Text> <TextInput style={styles.textInput} placeholder="이름을 입력해주세요." placeholderTextColor="#666" onChangeText={onChangeName} value={name} textContentType="name" returnKeyType="next" clearButtonMode="while-editing" ref={nameRef} onSubmitEditing={() => passwordRef.current?.focus()} blurOnSubmit={false} /> </View> <View style={styles.inputWrapper}> <Text style={styles.label}>비밀번호</Text> <TextInput style={styles.textInput} placeholder="비밀번호를 입력해주세요(영문,숫자,특수문자)" placeholderTextColor="#666" onChangeText={onChangePassword} value={password} keyboardType={Platform.OS === 'android' ? 'default' : 'ascii-capable'} textContentType="password" secureTextEntry returnKeyType="send" clearButtonMode="while-editing" ref={passwordRef} onSubmitEditing={onSubmit} /> </View> <View style={styles.buttonZone}> <Pressable style={ canGoNext ? StyleSheet.compose(styles.loginButton, styles.loginButtonActive) : styles.loginButton } disabled={!canGoNext || loading} // || 로딩 중 일때는 회원가입 버튼 클릭 안되게 onPress={onSubmit}> { loading ? ( <ActivityIndicator color='white'/> // 로딩 ) : ( <Text style={styles.loginButtonText}>회원가입</Text> )} </Pressable> </View> </KeyboardAvoidingView> ); } const styles = StyleSheet.create({ textInput: { padding: 5, borderBottomWidth: StyleSheet.hairlineWidth, }, inputWrapper: { padding: 20, }, label: { fontWeight: 'bold', fontSize: 16, marginBottom: 20, }, buttonZone: { alignItems: 'center', }, loginButton: { backgroundColor: 'gray', paddingHorizontal: 20, paddingVertical: 10, borderRadius: 5, marginBottom: 10, }, loginButtonActive: { backgroundColor: 'blue', }, loginButtonText: { color: 'white', fontSize: 16, }, }); export default SignUp;
-
미해결[개정판] 딥러닝 컴퓨터 비전 완벽 가이드
데이터셋 바꾸기
질문이 있습니다. 제가 yolov5를 사용하기 위해 데이터셋을 ai hub라는 사이트에서 가져왔는데 데이터가 json파일과 사진 파일 밖에 안 들어있습니다. json 파일 안에는 데이터 전처리(바운딩 박스)가 다 되어 있습니다. 하지만 yolov5를 사용하려면 각 사진 파일마다 텍스트 파일이 있어야 하는데 혹시 json 파일을 안의 바운딩 박스 데이터를 각 사진의 텍스트 파일로 변환하는 방법이 있을까요?
-
미해결탄탄한 백엔드 NestJS, 기초부터 심화까지
jwt passport 질문입니다
2종류의 user테이블a_user, b_user 테이블을 가지고 있는데 각 유저테이블에 대해 jwt 검증을 나눠서 하고싶은데..아무리해도 안되는데 팁이 있을까요
-
해결됨[리뉴얼] React로 NodeBird SNS 만들기
passport module에 대해 질문이 있습니다.
안녕하세요 passport-local를 사용할 때 username만 받게 되면 원래 안되는건가요? 제가 프로젝트를 진행하는데 메타마스크에서 지갑주소만 프론트에서 전달해주면 자동으로 로그인 되게끔 할려고 하는데 passwordField에 입력을 아예 안하면 401 에러만 자꾸 떠서 어쩔 수 없이 넣긴하였는데 형식상 nickname에 임의로 넣어서 postman에서 잘 동작 되는 것을 확인했습니다. module.exports = () => { passport.use(new LocalStrategy({ usernameField: `wallet_address`, passwordField: `nickname` }, async (wallet_address,nickname, done) => { try { const user = await User.findOne({ where : { wallet_address: wallet_address} }); if (user.wallet_address === wallet_address) { return done(null, user) } else { return done(null, false, { message: '가입되지 않은 회원입니다.' }); } } catch (error) { console.error(error); return done(error); } })); }; 그런데 logout을 강의처럼 코딩해서 했는데 Executing (default): SELECT `id`, `wallet_address`, `nickname`, `description`, `img_src`, `createdAt`, `updatedAt` FROM `users` AS `User` WHERE `User`.`id` = 1; POST /user/logout - - ms - - 이런식으로 떠서 동작이 잘 안되는거 같아서 이곳 저곳 뒤져봤는데 해결책을 마땅히 찾을 수 없어서 의심되는 부분이 password를 빼먹어서 그런가 싶어서 여쭈어보고 저는 비번을 딱히 사용을 원치 않는데 이것이 문제라면 혹시 이런 필수 파라미터를 제약 받지 않는 다른 모듈도 있는건가요?
-
미해결[C++과 언리얼로 만드는 MMORPG 게임 개발 시리즈] Part1: C++ 프로그래밍 입문
몫과 나머지 print하기
- 학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요! - 먼저 유사한 질문이 있었는지 검색해보세요. - 서로 예의를 지키며 존중하는 문화를 만들어가요. - 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요. 몫은 al로, 나머지는 ah로 가는 것까지는 알겠습니다. 그런데 mov al, ah를 하는 이유가 궁금합니다. (PRINT_DEC ah를 하는 경우, 오류가 발생하는데, 왜 오류가 발생하는지 궁금합니다.)
-
미해결[C#과 유니티로 만드는 MMORPG 게임 개발 시리즈] Part3: 유니티 엔진
매니저 구현 부분 질문이 있습니다.
인풋 매니저나 리소스 매니저 등등 여러 매니저를 구현하실 때 도통 이해가 잘 되지 않습니다... 개념 이해하지 못하고 무작정 클론 코딩만 하고 있는데, 일단은 넘어가도 괜찮을까요?
-
미해결설계독학맛비's 실전 Verilog HDL Season 1 (Clock부터 Internal Memory까지)
맛비님 보드질문드립니다
안녕하세요!! 강의에서 사용하는 보드는 Z7-20을 사용중인것으로 알고있는데 현재 계속 품절상태라서 구매를 할 수가 없는데 Z7-10보드를 사용을 하여도 실습하는데 문제가 없나 질문드립니다
-
미해결냉동코더의 알기 쉬운 Modern Android Development 입문
LiveData implementation
implementation 'androidx.lifecycle:lifecycle-livedata-core-ktx:2.3.1'도 안되서 2.3.1 로 버전내렸습니다.
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
stack의 선언 위치에 대한 질문
자료구조 stack을 일반 변수 선언하듯이 main 메서드 바깥에 선언했는데 메인문 안에 선언하는 것과 답이 다릅니다. 변수 생명주기와 관련있는건가요?
-
미해결자바 ORM 표준 JPA 프로그래밍 - 기본편
설계
실무에서 테이블 설계와 엔티티 설계,매핑 이런 작업은 개발자가 직접하는건가요?
-
해결됨게임 프로그래머 취업 전략 가이드
클라이언트, 포트폴리오 질문 입니다.
약 반년 전 해당 강의의 포트폴리오 목차를 수강하다가, "기술적인 난이도"라는 키워드에 이상하게(?) 꽂혀 장작 7개월이라는 긴 시간 동안 DX12로 여러가지 기술을 포트폴리오에 적용 하였습니다. 최근 게임에서 많이 사용되고 있는 기술인, 모핑을 이용한 캐릭터 얼굴 커스터마이징, 표정 변환, Physx를 이용한 Cloth Physics, Soft Body 시뮬레이션, 다이나믹 본, 애니메이션 복제, Shape Key, 멀티 렌더링 등등 실제 게임에서 많이 사용되는 것 같은 기술들을 위주로 하여, 포트폴리오에 적용 시키려고 노력하였습니다. 그런데 요즘드는 생각이, 대부분의 포트폴리오를 보면서 느끼는게 기술적인 요소는 딱 필요한 정도만 넣고 남은 시간동안은 게임의 퀄리티를 높이는 식의 포폴이 대부분인 것을 보면서 내가 옳은 길로 가고있는 것이 맞는지, 이상한 길로 가는 건 아닌지 하는 의심이 들기도 하고, 여러가지 기술을 추가하다보니 시간도 너무 많이 흘러 버려서 두렵고 후회스럽기 까지 합니다. 그래서 최종적으로 제 고민은 "포트폴리오에서 기술은 다다익선이 될 수 있는가?" 여부가 궁금해서 질문을 올리게 되었습니다. 개인적인 욕심 때문에, 괜히 회사에서 요구하지도 않는 부분까지 너무 깊게 삽질을 하여 1년이라는 시간을 버린건 아닌지 하는 의구심 때문에 요즘 많이 후회스럽고 힘이 드네요..
-
미해결스프링 핵심 원리 - 기본편
@Configuration
package hello.core.autowired;import hello.core.AutoAppConfig;import hello.core.discount.DiscountPolicy;import hello.core.member.Grade;import hello.core.member.Member;import lombok.RequiredArgsConstructor;import org.assertj.core.api.Assertions;import org.junit.jupiter.api.Test;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.context.annotation.AnnotationConfigApplicationContext;import java.util.List;import java.util.Map;import static org.assertj.core.api.Assertions.*;public class AllBeanTest { AnnotationConfigApplicationContext ac=new AnnotationConfigApplicationContext(DiscountService.class, AutoAppConfig.class); @Test void findAllBean(){ DiscountService discountService = ac.getBean(DiscountService.class); Member member=new Member(1L,"MEMBER", Grade.VIP); int discountPrice = discountService.discount(member, 10000, "fixDiscountPolicy"); assertThat(discountService).isInstanceOf(DiscountService.class); assertThat(discountPrice).isEqualTo(1000); } @RequiredArgsConstructor static class DiscountService{ private final Map<String, DiscountPolicy> polyMap; private final List<DiscountPolicy>policies; public int discount(Member member,int price, String discountCode) { DiscountPolicy discountPolicy = polyMap.get(discountCode); return discountPolicy.discount(member,price); } }}이코드에서@RequiredArgsConstructorstatic class DiscountService{ private final Map<String, DiscountPolicy> polyMap; private final List<DiscountPolicy>policies; public int discount(Member member,int price, String discountCode) { DiscountPolicy discountPolicy = polyMap.get(discountCode); return discountPolicy.discount(member,price); }}이부분을 스프링 컨테이너에 등록을 했습니다.그러면 DIscountService는 빈으로 등록이 됫습니다.그리고 @AutoWired가 생략이 되었을 뿐 의존관계 자동주입은 됫습니다.1. 하지만 여기서는 @Configurration이 없으므로 싱글톤은 보장이 안되는 것입니까??2. 다른 질문을 보니까 @Component가 붙으면 자동으로 싱글톤이 유지가 된다던데@Bean으로 Bean을 등록하면 Configuration이 없으면 싱글톤이 유지가 안되고Component로 빈을 등록하면 Configuration이 없어도 싱글톤이 유지가 되는 건지 궁금합니다.3.그래서 DiscountService가 스프링 컨테이너에 등록이 될 때 Component가 붙어서 @Configuration없어도 싱글톤이 보장되는겁니까??
-
미해결[개정판] 딥러닝 컴퓨터 비전 완벽 가이드
yolov3 학습 과정 log파일로 저장 방법 질문
안녕하세요 교수님 yolo 학습 과정에서 shell에 출력되는 것과 같이 log파일로 저장할 수 있는 방법이 있는지 문의드립니다. 감사합니다.