How should two vue projects be reused when they have some of the same pages and components?

the two projects cannot be merged into one project because most things are different and different dependencies and different build methods need to be introduced.

and there are a lot of reused pages and components between these two projects, how to deal with this part of the code is the best practice?

Sep.17,2021

encapsulates the component copy paste
the same as you use UI framework

if it is useful for git management, it can be extracted into a project for independent maintenance, and other projects can be introduced in the form of sub-modules.
just like I wrote a el-admin project based on element-ui . Now basically writing background projects depends on this sub-module, and it is convenient to update each project with pull .
of course, even if you don't use git , you can copy and paste the entire project directory directly, but that's really hard

.
Menu