본문 바로가기
블로그 이미지

방문해 주셔서 감사합니다! 항상 행복하세요!

  
   - 문의사항은 메일 또는 댓글로 언제든 연락주세요.
   - "해줘","답 내놔" 같은 질문은 답변드리지 않습니다.
   - 메일주소 : lts06069@naver.com


전체 글674

[Vuejs] setup function returned a promise, but no <Suspense> boundary was found in the parent component tree 뷰 개발 환경에서 만날 수 있는 경고문구 입니다. setup function returned a promise, but no boundary was found in the parent component tree 라우터 기반의 환경에서 라우팅 되어야 할 컴포넌트에 setup 부분에 반환 형태가 promise 인 경우 해당 경고문구와 함께 아무것도 뜨지 않을 수 있습니다. * 대상 : 샘플 vue 파일 이때 라우팅하는 파일에 keepAlive 노드를 붙여주믄 해당 문제는 해결 가능 합니다. 2023. 10. 16.
Vuejs 인덱스 파일 사용하기(index.js, index.ts) 파일 형식은 아래와 같습니다. * 파일 이름 : index.js export { default as 이름1 } from './이름1.vue' export { default as 이름2 } from './이름2.vue' export { default as 이름3 } from './이름3.vue' 해당 파일을 만들어준 뒤에 사용법은 기존 인덱스 파일 사용법과 동일 합니다. 간단 정리 끝! * 굳이 저렇게 사용하실꺼면..차라리 글로벌 컴포넌트로 등록하시는 걸 추천드립니다. 2023. 10. 16.
Mongoose array (몽구스 배열) 간단하게 정리한 몽구스에서 배열 데이터를 관리하는 방법 입니다. * 샘플 데이터 구조 #도큐먼트 구조 ## 1번데이터 { key : 'a', group : [ { id :'aaa', number : '1234'}, { id :'bbb', number : '5678'} ] } ## 2번데이터 { key : 'b', group : [ { id :'ccc', number : '1234'}, { id :'ddd', number : '5678'} ] } ## 3번데이터 { key : 'c', group : [ { id :'eee', number : '1234'}, { id :'fff', number : '5678'} ] } #1. 배열 데이터 조회 : group 필드의 배열 값에서 id가 'aaa' 인 것 찾아오.. 2023. 9. 12.
데이터 전송, 415 오류 (415 Unsupported Media Type) 웹 프론트에서 form 데이터 형식을 통해 서버와 응답하는 경우 만날 수 있는 오류 입니다. form 데이터에서 특정 데이터의 타입을 application/json으로 지정하지 않으면 발생 할 수 있습니다. 기본적인 form 데이터를 통해 데이터를 전송하는 방법 입니다. const formData = new FormData() formData.append('키', '값') formData.append('파일데이터키', file) const header = { headers: { 'Content-Type': 'multipart/form-data' }, transformRequest: [ function () { return formData } ] } axios.post('주소', formData, type.. 2023. 9. 8.
[Vue warn] Extraneous non-emits event listeners ... vuejs 3 [Vue warn]: Extraneous non-emits event listeners (.....) were passed to component but could not be automatically inherited because component renders fragment or text root nodes. If the listener is intended to be a component custom event listener only, declare it using the "emits" option. at at > at at at at at at at 뷰 환경에서 만날수 있는 경고문구 입니다. 해당 경고문구는 정의되지 않는 html element 이벤트를 사용자가 사용할 경우 발생 합니다. *.. 2023. 8. 23.
NestJS SSE (Server-Sent Events) sse는 서버에서 이벤트를 발행하여 웹 브라우저에서 해당 이벤트를 수신하는 기능 입니다. 웹소켓보다 훨씬 더 경량화 되어있고 단순한 이벤트를 전달 할 때 효과적이기 때문에 간단한 내용을 보낼 때 주로 사용된다고 합니다. 구현 방법은 어렵지 않습니다. * 컨트롤러.ts import { Controller, Sse } from '@nestjs/common'; import { interval, Observable } from 'rxjs'; import { map } from 'rxjs/operators'; @Controller() export class SseController { @Sse('sse') sse(): Observable { return interval(5000).pipe( map((_) => (.. 2023. 7. 19.