fullStack

fullStack

깊지 않은 npm 과 npx 차이

npm 첫번째 역할은 라이브러리들을 담는 레지스트리 역할 두번째 역할은 배포를 할 때 빌드를 하는 역할 대부분 -g를 붙이지 않으면 로컬로 isntall 됨 -g 는 뭘까? 내머신(컴퓨터)에 다운을 받는 느낌 원래는 create-reaact-app 을 할때 npm install -g create-react-app 이렇게 했었다.. 글로벌로 다운을 받았었다.? 하지만 최신에는 npx create-react-app . 이런식으로 npx 를 사용하여 인스톨함 이렇게 npx 를 이용하여 다운을 받는데 그 장점은 -g를 사용하지 않아서 1. 내 머신(컴퓨터)의 disk space를 차지하지 않는다. 2. npx가 npm registry에서 다운로드없이 실행시키므로 항상 최신버전을 사용할 수 있다. 이 정도로만 이..

fullStack

MongoParseError: options usecreateindex, usefindandmodify are not supported

mongoose를 이용해서 내 application과 MongoDB를 연결하려고 시도 중 error 발생 MongoParseError: options usecreateindex, usefindandmodify are not supported 수정전 mongoose .connect(URI, { useNewUrlParser: true, useUnifiedTopology: true, useCreateIndex: true, useFindAndModify: false, }) .then(() => console.log('MongoDB Connected...')) .catch((err) => console.log(err)); 수정후 mongoose .connect(URI) .then(() => console.log(..

deice
'fullStack' 카테고리의 글 목록