When comparing NW.js (w/xvfb) vs ASP.NET Core, the Slant community recommends NW.js (w/xvfb) for most people. In the question“What are the best tools for building cross-platform desktop apps with web technologies?” NW.js (w/xvfb) is ranked 2nd while ASP.NET Core is ranked 5th. The most important reason people chose NW.js (w/xvfb) is:
The integration of Node with the DOM in NW.js opens up a number of new options in how your headless testing workflow can be facilitated. The distinct separation of JavaScript contexts, the introduction of a separate node context, and the ability to cross communicate, offers a lot of power and flexibility.
Specs
Ranked in these QuestionsQuestion Ranking
Pros
Pro Node integration
The integration of Node with the DOM in NW.js opens up a number of new options in how your headless testing workflow can be facilitated.
The distinct separation of JavaScript contexts, the introduction of a separate node context, and the ability to cross communicate, offers a lot of power and flexibility.
Pro NaCl support/integration
Access to the Native Client offers up more options in implementing your testing workflow.
Pro Fast and getting faster
Thanks to breakthroughs in ROSLYN compiler and the efforts of the .NET COre developer team, code written in C# can reach speeds just a step behind C++.
Pro Multi platform
Can run on Windows, Linux and Mac (also Visual Studio Code editor).
Pro JSON optimization
In .NET Core 2.1 and 3.0, new APIs are added that make it possible to write JSON APIs that require less memory, using Span<T> and UTF8 strings, and improve throughput of applications like Kestrel, ASP.NET Core web server. See also Utf8JsonReader.
Pro Tutorials and documentation quality
Both microsoft and 3rd party tutorials are mostly of high quality and encourage you to use the industry best-practices.
Pro Built-in middleware
Built-in middleware featuring: Authentication, Cookie policy, Health Check, MVC, Session etc.
Pro Hosting
Ability to host on IIS, Nginx, Apache, Docker, or self-host in your own process.
Pro Ease of Use
Pro Security
It is a very secure platform.
Pro Tooling
Both VS and VSCode are powerful free IDEs that are well integrated with ASP.net Core. VS Community also allows for commercial use for projects with less than 5 developers.
Cons
Con xvfb Requirement (for now)
Headless is on the NW.js roadmap, but for now xvfb is necessary to get going. The community has done the work and you can find the details here.