In my last post I covered using Xamarin Studio and VS Code on a Mac. Microsoft had some big announcements at Connect(); // 2016, including re-branding Xamarin Studio as Visual Studio for Mac and including support for .NET Core in it (which has just shipped version 1.1).
This has left some people confused as to whether it's best to us Visual Studio Code or Mac. Not all of the tooling has caught up to the latest standards yet and plenty of things have changed. Here are my first impressions after trying out the previews.
ASP.NET Core 1.1
ASP.NET Core version 1.1 has shipped, along with the release of .NET Core version 1.1 that forms its foundation. These include a lot of improvements such as better support for third party Dependency Injection frameworks and proper output caching. Previous versions could set caching headers on responses but couldn't store the results on the server (you can read more about this in my book 😃).
However, 1.1 is not a Long Term Support release. It is a "Current" release and will be superseded by 1.2 when it is released sometime in Q1 2017. If you want patches and stability for many years then you should stick with 1.0.1, in much the same way as Ubuntu Linux LTS is a good choice for a production server.
The version of .NET Standard hasn't changed and remains at 1.6. Version 2 will coincide with a .NET Core release next year (1.2/1.3). This is really only an issue for packages or if you want to easily share code across Xamarin and .NET Core.
Some package maintainers were waiting for 1.1 before adding .NET Core support. However, many popular libraries are already supported. You can check the current status with my ASP.NET Core Library and Framework Support project at ANCLAFS.com. If you spot an error or want to add something then please get involved on GitHub, like many others have.
You can download the LTS (1.0.1) and "Current" (1.1.0) releases from Microsoft but the preview CLI tooling is lagging behind a little. For example, it doesn't yet create the new (old) project structure that Visual Studio for Mac uses.
Visual Studio for Mac
You can download the preview of Visual Studio for Mac but it is still very much a preview and has some quirks. Installation was straightforward and pretty quick. As with all Microsoft preview software, you can't disable the usage tracking and crash reporting.
When you first launch VS Mac you can create a new project and the templates now include .NET Core projects, including an ASP.NET Core web application.
The initial project starts with v1.0.1 but you can update the packages to v1.1.0. This took a few attempts to get it to work and not remove all the packages. You will need to install .NET Core separately, but the CLI tools that come with that still use the old JSON project style. You can open the solution folder in VS code to see the new XML one.
What's old is new again and Microsoft have dropped the
project.json file. They have gone back to the old XML
.csproj format, albeit a much smaller and cleaner version.
VS for Mac and VS Code are very different products. If you are on a Mac and want to stick with the LTS version of ASP.NET Core (1.0.1) then VS Code is best. If you would prefer to use the bleeding edge "Current" version of ASP.NET Core (1.1.0) then it looks like VS for Mac will be a good choice. However, the CLI tools will be updated and then VS Code may also work well.Submit / Comment on Hacker News