Integrate Angular Application with Asp.net Core 2.0 in Visual Studio 2017(works with vs 2019)

preview_player
Показать описание
In this video you learn step by step how to add Angular Application to your .net core 2 project using visual studio 2017 and npm
demonstrated by keyvan Janghorbani
Рекомендации по теме
Комментарии
Автор

0:00 Intro
1:35 Install required software
3:13 Warnign about creating Angular project with dotnet in VSC
4:43 Steps
8:08 Add two packages to .csproj file: MVC and StaticFiles
10:18 Edit Startup.cs and enable MVC
14:23 Let's run the .NET app
15:17 Add the Angular app to the project
17:57 Move Angular project to the root of our app
18:37 Edit Angular JSON and TS files
24:49 Ready to build the project
26:12 Let's test the Angular app
27:16 Some troubleshooting
28:05 How to publish the app

dariocosta
Автор

Thank you very much for this! I had to search quite a bit before I found such a clear explanation of how to integrate Visual Studio with Angular. One issue I had was at the end with the publishing. I had to replace the line:
<Exec Command="ng build -prod -aot" />
With the line:
<Exec Command="ng build --prod --aot" />

belmiris
Автор

this video has focus, clarely and time spent on it, it is very productive! You are a crack!, very Tank you! fogiveme my bad english :)

lwolfur
Автор

Awesome video! Nice explication in 30 minutes, thank you very much!I was able to deploy my first angular App with .net core from Visual studio 2019 onto azureDevops pipeline

zipzapzoom
Автор

Thank you so fucking much. This is the only tutorial that actually worked for me. Even though you could have sped it up a little, I'm still very grateful.

TheTaltiko
Автор

This video has been very helpful, thanks.

pamanes
Автор

Awesome video! Nice explication in 30 minutes, thank you very much!

israelborja
Автор

weird you would have to make many hacks into the csproj files..., and also do a lot of plumbing in the startup... isn't there a default way to do mvc, webapi and angular in VS?... if that's even a thing to do... just new to this.
Also do we need to use .net core for angular, or can we use .net framework as well?

Jubinmail
Автор

Thank you for the video. Super helpful :)

garth-baker-blog
Автор

Your Video, has focus, clearly and time spent on it, for me, it is productivity, Thank you!

gabrieldelgado
Автор

Thank you for sharing this. I've been using ASP.NET and love the framework Angular gives; however, I hate the difficulty in copying each file, changing code, and repeat on each app I do. (Of course you can just copy the app and then edit coding, but still agitating.)

GeekSire
Автор

the package aspnet core all adds the mvc and staticfiles dependencies. also adds ef and a bunch of other stuff. so there's no need for other dependencies.

bjkr
Автор

thanks for the tutorial, but why not just use NuGet for getting all AspNetCore proper references?

yuriihanzha
Автор

Hi, thank you for video.
I have a question. Why are you moving angular app into solution root? I see it quite messy and keep it in subfolder looks better and works the same, or not?

MartinMikulaPrespic
Автор

I just ran this guide again. I needed change the build command to <Exec Command="ng build --prod --aot" />

The only change is to add double dash in stead of singe dash on the parameters.

srlatsrldotdk
Автор

The screen was really blurry to read the text at the end. The code that was cut and pasted into the .csproj is this:
<Target Name="Build Angular" BeforeTargets="Build">
<Message Text="Build in Process" Importance="high"/>
<Exec Command="ng build -prod -aot" />
</Target>

scottjohnson
Автор

You can enter csproj file inside VS by rightclicking your visual studio project and select "Edit projectName.csproj" it from the dropdown.

jonathankirkegaard
Автор

Nice explanation in 30 mins - great! Why did you not use Nuget for adding the two PackageReference entries to the csproj? @09:20

JamesPoulose
Автор

This video is very informational, thanks. I wonder how to code the following scenario in angular, 1 SQL database fille containing multiple user rows, how can a login user access her own rows?

dkyosk
Автор

I am new to angular i didn't understand one thing that when you save result.json as string[] in this.apiValues[] array at 23:30 then how you get values from a result[] in string interpolation in app-component.html . Shouldn't you use apiValues in the string
interpolation ? Please explain

fahadbaig