JJAE CODING DIARY

  • 홈
  • 태그
  • 방명록

express_static 1

node express에서 html, js, css파일 정상적으로 불러오기

express에서 html을 불러올 때는 주의해야 할 사항이 있다. 우리는 보통 다음과 같은 방식으로 html을 연결하곤 하는데, 이렇게 하면 해당 html에 script로 박아넣은 js파일이나 css파일 등을 바로 읽지 못하고 오류가 날 수 있다. 이를테면 아래처럼 html 파일을 연결했을 때, 아래처럼 404에러가 줄줄이 뜨는 것을 확인할 수 있을 것이다. 해당 오류에 대해서는 아래 페이지에서 해답을 찾을 수 있었다. Serving static files in Express Serving static files in Express To serve static files such as images, CSS files, and JavaScript files, use the express.static bu..

TIL 2022.11.30
이전
1
다음
더보기
프로필사진

JJAE CODING DIARY

코딩 좋아해요 진짜루

  • 분류 전체보기 (21)
    • 잡담 (2)
    • TIL (19)

Tag

스프링부트로그, 리액트cors에러, reactproxy에러, proxy에러, express_static, SpringBoot, mvc흐름, expresshtml, 프록시에러, 스프링부트, 스프링부트react연동, http-proxy-middleware, springbootgradlelog4j2, express정적파일, 스프링부트proxy, 스프링부트리액트, 스프링부트cors, express에서js, springbootgradle로그, yarnstart에러,

최근글과 인기글

  • 최근글
  • 인기글

공지사항

페이스북 트위터 플러그인

  • Facebook
  • Twitter

Archives

Calendar

«   2025/10   »
일 월 화 수 목 금 토
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31

Copyright © Kakao Corp. All rights reserved.

티스토리툴바