I bought the book to try and get started in angular on a basic level with a .NET Core web api as a backend. I think the main issue I've had (and have in the past encountered this with other microsoft templates), is that the default project is very "fragile" to change and it can be difficult for someone who is a beginner to understand just what went wrong and how to fix it.
The health check project was the first one where I encountered this issue, but was able to get around it with the authors fixes. WorldCities was an entirely different story: Even the code pulled down from the repo didn't work.
In my opinion, I think the better approach is to build the .net core API as a headless system, test that with postman first, and then hook up the react/angular project. It is way easier to deal with angular in isolate than to deal with it via Visual Studio.
Another problem I ran into is that the project for WorldCities uses system.linq.dynamic.core, and doesn't mention it until after the code block that uses it. I'd recommend to the author that at the start of each chapter, he/she list out any third party nuget packages needed for the exercises.
What I find rather odd about chapter 5 is that the author admits that SQL Injection attacks are a problem when using a loosely typed approach offered by system.linq.dynamic.core, and then goes on to create a validation method that also makes use of reflection to validate the column being referenced in a sorting operation. So not only is the approach being used in the chapter open to SQL Injection and has overhead due to reflection, it also has even more overhead because of the validation method also using reflection! Less experienced developers often template out code they find in a book and reuse it elsewhere, so I encourage those writing code to use due vigilance when producing books meant to instruct others.
无需Kindle设备,下载免费Kindle阅读软件,即可在您的手机、电脑及平板电脑上畅享阅读。
请输入您的手机号码,获取Kindle阅读软件的下载链接。
