Using the VS Code development to debug ASP. NET Core 1.0, Microsoft released the 1.0,asp.net Core 1.0 and Entity Framewok 1.0 early this morning.
Before you explained the VS code development debugging. NET Core RC2 applications. Today, let's talk about vs code developing ASP.
Environment installation
. NET Core SDK Installer:
Win x64:
https://download.microsoft.com/download/A/3/8/A38489F3-9777-41DD-83F8-2CBDFAB2520C/packages/ Dotnetcore.1.0.0-sdk.preview2-x64.exe
If the SDK has RC2 installed, please uninstall and install it first.
More versions to download:
Https://www.microsoft.com/net/download
Vscode:
https://code.visualstudio.com/
Vscode C # Extensions:
Ctrl+p Open the Quick Open input: ext install csharp Select C # installation.
Reboot vs Code after installing the plugin.
Create a project
First make sure the DOTNETCORE.1.0.0-SDK installation is successful.
Dotnet--version
The output is as follows:
1.0.0-preview2-003121
You can then create a project with. NET Core 1.0 Additions to create the Web project.
dotnet NEW-T Web
dotnet Restore
Dotnet Run
CTRL + C stops the project and uses vs Code to open the Aspnetcore folder.
If this is the first time you've opened a C # project with VS Code, you'll need to wait for it to download. NET Core Debugger.
Appears as shown, the representative installs well. Then click Yes
Then we cut to debug module, click Debug.
Successful debugging, VS Code will automatically open http://localhost:5000
Install Yo
First we need to install Nodejs and then the command line input:
NPM Install-g yo
NPM install-g generator-aspnet
So we can generate projects, controllers, and view through Yo
Add Controller
Yo Aspnet:mvccontroller Democontroller
Add View
We create a new demo folder and add the view below
Yo Aspnet:mvcview Index
Visit: Http://localhost:5000/demo
Debugging:
The direct down breakpoint can be debugged.
If you think this article is helpful to you, please click " recommend ", thank you.
Reference page:
Http://www.yuanjiaocheng.net/CSharp/csharp-dynamic-type.html
Http://www.yuanjiaocheng.net/entity/add-entity-graph.html
Http://www.yuanjiaocheng.net/entity/add-entity-in-disconnected.html
Http://www.yuanjiaocheng.net/mvc/create-edit-view-in-asp.net-mvc.html
Http://www.yuanjiaocheng.net/mvc/mvc-helper-hiddenfield.html
Http://www.yuanjiaocheng.net/CSharp/Csharp-arraylist.html
Http://www.yuanjiaocheng.net/entity/mode-first.html
Http://www.yuanjiaocheng.net/CSharp/csharphuanjing.html
Http://www.yuanjiaocheng.net/CSharp/Csharp-if-else.html
Http://www.yuanjiaocheng.net/CSharp/Csharp-stack.html
Http://www.yuanjiaocheng.net/CSharp/Csharp-while-loop.html
Debug ASP. NET Core 1.0
with VS code development