Comments (9)
Hey! Your argument passing looks fine to me. You'll need to specify a return type though.
Your C#:
var image = await StaticNodeJSService.InvokeFromFileAsync("test_nodejs_script.js", args: new [] { exportSettings });
Expected C#:
var image = await StaticNodeJSService.InvokeFromFileAsync<your return type here>("test_nodejs_script.js", args: new [] { exportSettings });
Your return type must be a JSON-serializable type, string
, or Stream
.
As for debugging: instructions, example options.
Let me know if you need further help.
from javascript.nodejs.
Thanks for your help. I still cannot get debugging going. I added debugger statement to my JS code. I also have Nodejs console open, but it's not getting into debugging.
from javascript.nodejs.
I've created an example project:
- Clone and run
- Navigate to chrome://inspect/ in Chrome
- Click "Open dedicated DevTools for Node" and wait for the debugger to attach
from javascript.nodejs.
It worked just once, after that is not attaching to the Browser no matter what.
from javascript.nodejs.
In Edge I am getting into this:
from javascript.nodejs.
When I run it in the VS2019 I get command window open which says:
C:\Test.NodeJS.Debugging-main\bin\Debug\netcoreapp3.1\Test.NodeJS.Debugging.exe (process 4156) exited with code 0.
To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops.
Press any key to close this window . . .
from javascript.nodejs.
I cleaned up a little and now command window opens blank, but still no debugging.
from javascript.nodejs.
After killing the running process once the next run will have:
C:\Test.NodeJS.Debugging-main\bin\Debug\netcoreapp3.1\Test.NodeJS.Debugging.exe (process 4156) exited with code 0.
To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops.
Press any key to close this window . . .
Which makes debugging pointless.
Killing node.js processes will help to recover debugging session in VS but no debugging in Chrome.
Now I am getting:
No devices detected. Please read the remote debugging documentation to verify your device is enabled for USB debugging.
Do you have another example?
from javascript.nodejs.
The example project works on my machine. Unfortunately this looks like a machine-specific issue. Closing for now, feel free to open a new issue if you have questions.
from javascript.nodejs.
Related Issues (20)
- Call the same instance?
- Has anyone used this with React/JSX?
- Facing issue with Jering.Javascript.NodeJS HOT 2
- Next.JS instead of Node.js
- Microsoft.AspNetCore.Hosting.Abstractions is obsolete HOT 2
- Delayed FileWatching: Maybe a OutOfProcessNodeJSServiceOptions property? HOT 2
- Suitable constructor for Jering.Javascript.NodeJS.HttpClientService Exception HOT 2
- NodeJS server is not recognised when invoked HOT 15
- Jering.Javascript.NodeJS.HttpNodeJSService[0]. An invocation attempt failed
- running the cypress via node in C# giving error "Could not find Cypress test run results" HOT 1
- Exception: "The semaphore has been disposed" on release 7.0.0 HOT 2
- ConnectionException: Process with ID 83312 exited before connecting. HOT 28
- Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host.. HOT 1
- require cache update, concurrent problem HOT 2
- Only URLs with a scheme in: file, data, and node are supported by the default ESM loader. HOT 4
- InvocationException: Unexpected reserved word HOT 3
- SocketException - An existing connection was forcibly closed by the remote host HOT 1
- Jering.Javascript.NodeJS.InvocationException - resolvedPath.replaceAll is not a function HOT 3
- Similar to Microsoft/node-api-dotnet project?
- InvokeExportAsync?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from javascript.nodejs.