从C#.NET调用Node.js [英] Calling Node.js from C# .NET

查看:1181
本文介绍了从C#.NET调用Node.js的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以从C#ASP.NET服务器调用Node.js函数? 我找到了Edge.js库,但据我了解,它允许Node.js调用C#.我需要直接反向解决方案.

Is it possible to call Node.js functions from a C# ASP.NET server? I found the Edge.js library, but as I understood, it allows Node.js to call into C#. I need the directly reverse solution.

推荐答案

Microsoft.AspNetCore.NodeServices

  • 这为.NET代码在Node.js环境中的服务器上运行JavaScript提供了一种快速而强大的方法.您可以使用它在运行时在ASP.NET Core应用中使用NPM软件包中的任意功能.

  • This provides a fast and robust way for .NET code to run JavaScript on the server inside a Node.js environment. You can use this to consume arbitrary functionality from NPM packages at runtime in your ASP.NET Core app.

大多数应用程序开发人员不需要直接使用它,但是如果您要实现自己的功能(涉及在运行时从.NET调用Node.js代码),则可以这样做.

Most applications developers don't need to use this directly, but you can do so if you want to implement your own functionality that involves calling Node.js code from .NET at runtime.

来源: https://github.com/aspnet/JavaScriptServices

这篇关于从C#.NET调用Node.js的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆