Duplicate functionality among several projects

I am currently working on two social networking sites that have a lot in common but are still different from each other. I find that I write a lot of the same code for both (including the user interface), and wondered if there is any best practice that will limit duplicate code.

One of the main problems is that these projects are very independent from each other and are likely to have more differences than similarities in the near future. In addition, once the initial work is completed, they can be transferred to other programmers, so using shared code libraries can be a big problem.

Any suggestions from people who could deal with a similar situation?

PS: I am the only developer in both of these projects, and it looks like he will stay that way for a while.

+3
source share
2 answers

- . , , , , . , , - , . . , ( , ).

, , - , . . , , , , , , . YAGNI ( ) , .

+5

( ) , , , . -, - . , , , , - - . , , . , , ( ) .

, , . , , , . .

, . , 2 ( ), , , .

+1

Source: https://habr.com/ru/post/1705910/


All Articles