Javascript.NodeJS
Javascript.NodeJS copied to clipboard
Suitable constructor for Jering.Javascript.NodeJS.HttpClientService Exception
First let me say Thank You. I got your library to work on a console project to test the functionality and it worked as expected (even better).
I'm now creating an asp.net app .NET Framework 4.7 and I'm receiving the following error:
A suitable constructor for type 'Jering.Javascript.NodeJS.HttpClientService' could not be located. Ensure the type is concrete and all parameters of a public constructor are either registered as services or passed as arguments. Also ensure no extraneous arguments are provided.
If anyone could help or point me in the right direction I would greatly appreciate it.
For more context, I've tried both the StaticNodeJSService and DependencyInjection.
//
var services = new ServiceCollection();
services.AddNodeJS();
ServiceProvider serviceProvider = services.BuildServiceProvider();
INodeJSService nodeJSService = serviceProvider.GetRequiredService<INodeJSService>();
var t = await nodeJSService.InvokeFromStringAsync
And:
//
var t = await StaticNodeJSService.InvokeFromStringAsync
Hi, what package version are you using?