3

I loaded Visual Studio 15.5.2 and then used the asp.net core with angular project template preview

to generate a project. It built and ran great. I have been looking at angular for the last month and using the angular/cli to generate apps and components. I have a problem understanding the angular preview template (both vs 15.3 and 15.5.2).

My questions are:

1) In the angular/cli template there is an index.html which is in the src directory. The asp.net angular has an index.cshtml and is in the Views\Home directory. Can this be placed in the base ClientApp directory (and of course change dir in places needed).

2) I want to be component based in angular, but I don't see how to add a component in Visual Studio 15.3 or better. If I am using angular/cli I can open a command prompt and go to my src directory and add from cmd line. How do I do that here?

Update: I found this question answered here but it leaves me asking why is the app.component.ts split across three files.

3) I need to use scss in my web app, in order to use Kendo UI with angular, but I am not sure if the template generated uses plain css or what. What is used in the template css or sccs? In angular/cli you can set the style when generating an app.

4) In angular tutorials everything can be done from the command line and has a certain directory layout. Why doesn't the asp.net core angular template use that layout. I am trying to focus on angular and get the benefits of asp.net core and controllers. But it seems like the worlds are somewhat different why is that?

5) Is there some tutorial video that shows whats is going on under the hood in the angular generated template, because at this point I am just confused. I want all the magic that comes from the hard work done by the asp.net core team but I need a better understanding of what is going on under the hood. I have seen the asp.net core 2 angular videos and articles:

https://www.codeproject.com/Tips/1208529/Angular-CLI-and-ASP-NET-Core-Angular-Template
https://dustinewers.com/angular-cli-with-net-core/
https://www.codeproject.com/Tips/1208529/Angular-CLI-and-ASP-NET-Core-Angular-Template
https://wildermuth.com/2017/07/10/ASP-NET-Core-2-VS2017-Angular-CLI
https://medium.com/@levifuller/building-an-angular-application-with-asp-net-core-in-visual-studio-2017-visualized-f4b163830eaa
https://www.youtube.com/watch?v=TbJSABCCtt8

However, with the different layout of some files and directories I am having a hard time bridging asp.net core and angular.

I know there are a lot of questions here and I do not want this to appear in any way to put the asp.net core 2 angular template in a bad light. I know the team along with Steve Sanderson have done great work. I am trying to marry what I have learned about angular to asp.net core 2.

Any help you can provide would be appreciated. (please do not edit the question to remove this it is important to thank people who take time out of their day for their help).

dgxhubbard
  • 703
  • 2
  • 7
  • 18

0 Answers0