먼저 다음과 같이 public디렉토리 ,profile.html,./public/index.html파일을 만듭니다.profile.html파일과 index.html파일의 내용은 아래에 있습니다.컬러 강조된 부분은 새로 추가된 코드 입니다.First, create the public directory, profile.html, and ./public/index.html files as follows.The contents of […]
Nodejs
Posted on:
NODEJS기본 http server ,NODEJS Basic http server(npm express,routing)
express 모듈은 커맨드라인에서 npm 명령어로 설치 할 수 있습니다.브라우저 주소를 통해서 웹사이트에 접속 할 때 도메인 주소 엔드 포인트에 따라 웹서버는 클라이언트에게 다른 내용을 보여 줄 수 있습니다.예를 […]
Nodejs
Posted on:
NODEJS기본 http server ,NODEJS Basic httpserver(ESM,COMMONJS)
nodejs에서 esm과 commonjs 방식의 http server code입니다.nodejs는 웹서버(http server)가 없습니다.코드로 웹서버의 기능을 구현합니다.기본적으로 nodejs는 포트번호 3000번을 사용합니다 .그래서 nodejs패키지인 react나 express만으로 웹사이트를 만든다면 리버스 프록시기능이 있는 Nginx가 좋은 […]
Nodejs
Posted on:
NPM moment module
nodejs를 설치 하고 npm명령어를 통하여 패키지를 설치 하면 사용 할 수 있습니다.기본 적인 패키지 설치 명령어는 아래와 같습니다.You can use it by installing nodejs and installing the package […]