21.2.2 프로젝트 생성

    이번에 만들 백엔드 프로젝트는 이 책에서 다루는 마지막 프로젝트인 블로그 서비스와 연동할 서버입니다. blog 디렉터리를 만들고, 그 내부에 blog-backend 디렉터리를 만드세요. 해당 디렉터리에서 yarn init -y 명령어를 실행하여 패키지 정보를 생성하세요.

    $ mkdir blog
    $ cd blog
    $ mkdir blog-backend
    $ cd blog-backend
    $ yarn init -y
    yarn init v1.12.3
    warning The yes flag has been set. This will automatically answer yes to all questions, which may have security implications.
    success Saved package.json

    이 작업을 하고 나면 디렉터리에 package.json 파일이 생성됩니다. 다음 명령어를 실행하여 해당 파일이 잘 만들어졌는지 확인해 보세요(혹은 에디터로 직접 열어 보아도 됩니다).

    $ cat package.json
    {
    "name": "blog-backend",
    "version": "1.0.0",
    "main": "index.js",
    "license": "MIT"
    }
    신간 소식 구독하기
    뉴스레터에 가입하시고 이메일로 신간 소식을 받아 보세요.