본문 바로가기
프로그래밍

nx workspace

by 자유코딩 2023. 3. 13.

nx project create

npx create-nx-workspace

 

npm i @nrwl/react
npx nx g @nrwl/react:application client

nest js 추가

npm i @nrwl/nest
npx nx g @nrwl/nest:app <app name>

react next

npm i @nrwl/next
npx nx g @nrwl/next:app my-new-app

전체 실행

npx nx run-many --target=serve

개별 실행

npx nx serve <app name>

만들어진 react-next 앱에 페이지 추가하기

nx g @nrwl/next:page my-new-page --project=my-new-app

nx g @nrwl/next:component my-new-component --project=my-new-app

댓글