Well, in prev. version of .NET adding a new project reference is quite straightforward, however in .NET Core is still a challenge (thanks to the missing tools). So, let's see how to reference your custom Foo.Lib into your Foo.Web project.
- Open project.json in Foo.Web
- Find frameworks tag
- Add a new tag "dependencies"
- Extend with your Foo.Lib under dependencies.
It should look like something similar:
"frameworks": {
"netcoreapp1.0": {
"dependencies": {
"Foo.Lib": "1.0.0-*",
},
"imports": [
"dotnet5.6",
"portable-net45+win8"
]
}
},
Recompile your whole solution and now you can use your lib in the web project.