This project is read-only.
NEWS (March 31, 2017)

In light of Codeplex shutting down, this is a reminder/notice that there is actually a Github page for this site as well, which you can find here:

NEWS (March 28, 2017)

I've been spelunking through much of the ASP.Net MVC Core source code, which is a cross-platform port of .Net (I would say sort of MS version of Mono). This will most likely become the new focus instead of Mono for cross-platform compatibility for V8.Net. Since .Net Core can support command line tool projects (uses the Kestrel web server by default), this means one could now start building cross-platform NodeJS type servers using V8 and .Net Core instead (MVC is injected, and is not needed if a pure V8 server was to be created instead).

Once I move to this route, .Net Core will become the focus of the project, but it is possible to target both .Net Full and .Net Core, so I hope one day a simple NuGet package can support both.

NEWS (May 27, 2015)
  • Added method {V8Engine}.SetFlagsFromCommandLine(string) to set command line options.
  • Added ability to terminate long script execution by calling {V8Engine}.TerminateExecution().
  • A complete re-vamp of the handle system is now in the dev branch; Much more efficient and reliable!
  • May 11: New release fixes a few bugs. This is an important update for x86 users that rely on the 'isContructCall' parameter of callbacks (includes some type/instance binding scenarios).
  • Latest dev branch update works with the latest Google source updates (as of April 18, 2015, using V8 commit ID `cb1b554a837bb47ec718c1542d462cb2ac2aa0fd`). Also, fixed a marshalling bug on Windows 8 systems.
  • V8.Net will soon be integrated into a new experimental project called "DreamSpace.NET", which uses V8.NET as the back-end server for a VPL (visual programming language) called "FlowScript" that compiles to JavaScript. This allows building apps from the client side, for both client AND server, and more, all in a single visual IDE. Lots of good stuff to come, so stay tuned ...
  • V8.NET now compiles on Mono, see here: (special thanks to chrisber01). While it now compiles, there's no "official" support for it just yet.

Project Description

A fairly non-abstracted wrapper for Google's V8 JavaScript engine.

What does that mean? Well, most other existing wrappers abstract most of the Google V8 engine's abilities away from you. That's fine for simple tasks, but wouldn't you rather have full control over the power of the V8 engine from managed code?

I've carefully crafted a C++ proxy wrapper to help marshal fast data transfers between the V8 engine and the managed side. One of the biggest challenges (which actually turned out to be simple in the end) was storing a field pointer in V8 objects to reference managed objects on call-backs (using reverse P/Invoke). A special custom C# class was created to manage objects in an indexed array in an O(1) design that is extremely fast in locating managed objects representing V8 ones.

Interesting note: I was carefully considering future portability to the Mono framework as well for this project, so great care was made to make the transition as seamless/painless as possible. ;)

License Clarification

The license is LGPL. In a nutshell, this means that you can link to the libraries from your own proprietary code (including code for commercial use), but if you modify the source files for anything in this project, the modified source and executables from it must also be made freely available as well (and you must clearly state you modified the code).

Coming in Next Release / WIP (updated on Jan 19th, 2015):

(NOTE: If I'm posting upcoming changes here, they are usually in the latest development-branch release binaries. Those binary releases will continue to be the bleeding edge releases.)
(see news at the top)

Completed Updates This Release
  • Fixed a bug where '{V8Engine}.call()' doesn't catch and return any exceptions. Previously, exceptions would cause 'undefined' to be returned.
  • Apparently Google has changed a lot of how the API works, and rearranged code in V8 namespaces, so those looking to build from the source had issues. I've fixed it for the most part (in the latest dev branch, including the binaries).
  • Because V8.Net is part of a larger project vision, I'm focusing on the other projects now. I'll be coming back to it off and on as required, and will try to get in some requests/fixes as soon as possible. Thanks, and have a great day! 8)

Future Ideas

I'll also be looking into the WebRTC SDK in the near future as well to help support networkable servers that are compatible to the supported browsers (currently Chrome and Firefox).

Last edited Mar 31, 2017 at 8:57 PM by jamesnw, version 105