使用Visual Studio 2017的.NET Core解决方案上没有project.json,global.json ...等

编程入门 行业动态 更新时间:2024-10-22 21:22:01
本文介绍了使用Visual Studio 2017的.NET Core解决方案上没有project.json,global.json ...等的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我做一个项目

File -> New -> Project -> Visual C# -> Web -> ASP.NET Core Web Application (.NET Core) -> Empty -> OK

但是没有解决方案和src目录,也没有project.json和web.config等.

But there is no solution and src directory and also no project.json and web.config etc.

我引用了一本使用Visual Studio 2015的书.本书的示例包含了我告诉过的所有文件和目录.但是我没有(我正在使用VS 2017,因为找不到用于VS 2015的.NET Core).

I reference a book that uses Visual Studio 2015. The book's example has all files and directories I told. But I don't(I'm using VS 2017 since I can't find .NET Core for VS 2015).

如何制作这些文件和目录? 我可以手动制作吗?

How can I make those files and directories ?? Do I make these by manually?

推荐答案

.NETCore正在以稍微较快的速度更改其内部结构(尽管现在看来已经解决了),因此使那里的许多教程都过时了. 自2016年中开始,该项目.json已被转储以支持您的应用名称" .csproj文件.

The .NETCore was changing its internals with a slightly fast pace (although it seems it has settled down now), thus making many of the tutorials out there obsolete. Since mid-2016, the project.json has been dumped in favor of "your-app-name".csproj file.

如果您正在学习教程或书籍,那么对于应该在project.json中编写的任何内容,现在都必须以略有不同的格式将其写入csproj文件中.

If you are following a tutorial or a book, then for anything you are supposed to write in the project.json, you must now write it in the csproj file with a slightly different format.

如果在后续教程中我必须弄乱project.json,我可以使用此官方迁移指南.

If i have to mess with project.json when following tutorials i use this official migration guide.

更多推荐

使用Visual Studio 2017的.NET Core解决方案上没有project.json,global.json ...等

本文发布于:2023-11-14 09:21:52,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1586831.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:解决方案   NET   Visual   Studio   json

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!