Reputation: 89
Getting error if I use serve for libraries:
An unhandled exception occurred: Project library_name does not support the 'serve' target. See "/tmp/ng-oggHbf/angular-errors.log" for further details.
Upvotes: 0
Views: 1699
Reputation: 1884
Yes, error is true. We can't serve angular library and even there is no point to serve the library since it's not application. Still if you want to test your library there could be 2 ways:
In package.json:
"dependencies": {
"library-name" : "file:<local dist folder location>"
}
I use to prefer second approach. You can also get detail explanation here: Angular serve library
Upvotes: 2