@Kmcnet , Welcome to Microsoft Q&A, let me answer your confusion.
But I see examples where the class library is included (and sometimes required to be included) in the consuming application solution. So is the class library developed initially within the consuming application?
It will be convenient for us to write the class library and consuming application in the same solution. You could also developed the Class Libraries separately.
What are the best practices for developing these libraries
Please refer to the following link to know how to deal with it.
What are best practices for developing class library in general and database layer specifically?
In C# what is best practice when setting up a project with dependencies (e.g. class library or separate files)
Best practice when developing a C# Library for use in multiple solutions/projects
In a conclusion, I think we need to consider the following things.
First, We could try to use the repository pattern in the Class Library.
Second, We could consider that we need to have a single code base maintaining the library.
Third, Please try to use Nuget when you used multiple versions of the library.
Hope my answer could help you.
Best Regards,
Jack
If the answer is the right solution, please click "Accept Answer" and upvote it.If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.