需求背景: 需要在 pc
端容器里嵌套一个 mobile
容器,相当于要同时启动两个项目。
将其定位为一个 monorepos
项目。
From lerna
Splitting up large codebases into separate independently versioned packages is extremely useful for code sharing. However, making changes across many repositories is messy and difficult to track, and testing across repositories becomes complicated very quickly.
$ mkdir lerna-repo && cd $_$ npx lerna init
script
details see lerna doc
why should add workspaces and private props in the root?
The root package.json usually not have any effect, and workspaces and private props are used together.
It seems it should be named @crd/theme instead of @crd-theme.