This looks really cool. I always wanted a small embeddable JS engine with a C interface. And it looks like you modelled the C API after the Lua C API? That is what I wanted as well. Here are some related projects I saved links to. I think there were a few others. http://code.google.com/p/tiny-js/ http://adaptive-enterprises.com/~d/software/see/ http://sourceforge.net/projects/njs/ v8 is an obvious open source impleme…
JavaScriptCore (the engine from WebKit) also has a very simple C interface (and I've seen it embedded by people as a static library without serious difficulty).
Duktape: an embeddable JavaScript engine
21–30 of 44 posts
Re: Duktape: an embeddable JavaScript engine
#22Earlier quoted context omitted.
JavaScriptCore (the engine from WebKit) also has a very simple C interface (and I've seen it embedded by people as a static library without serious difficulty).
It's LGPL though, which is too restrictive for some projects (especially as a static library).
Re: Duktape: an embeddable JavaScript engine
#23Why does the readme say "liberal license" when the license file is in fact "MIT license" Why hide the fact that it is under the MIT license? Why is there a folder called licenses and why does it contain an unfilled in license (Copyright (c) )?
The additional license is for another project (murmurhash2).
Re: Duktape: an embeddable JavaScript engine
#24If this is embedded in C++ I feel like you would be manipulating objects in the JavaScript scripts. JavaScript has OOP bolted on and it is not nearly as nice as Lua or similar alternatives. Why would a developer embed a JavaScript engine compared to something already existing?
Qt already uses JS in the form of QtQuick with quite a bit of success. JS using a prototypal system means that it can emulate almost any other OOP trivially (while the reverse is much harder). I prefer embedding lisp, but I realize that most developers don't know that language family (which mostly defeats the point of an embedded scripting language). JS seems to be the closest widely-known languages have come to this…
Re: Duktape: an embeddable JavaScript engine
#25Re: Duktape: an embeddable JavaScript engine
#26Re: Duktape: an embeddable JavaScript engine
#27Re: Duktape: an embeddable JavaScript engine
#28Re: Duktape: an embeddable JavaScript engine
#29If this is embedded in C++ I feel like you would be manipulating objects in the JavaScript scripts. JavaScript has OOP bolted on and it is not nearly as nice as Lua or similar alternatives. Why would a developer embed a JavaScript engine compared to something already existing?
I wouldn't describe JavaScript's OOP as bolted on. It's just a different kind of OOP - prototype based rather than class based. You could argue that Lua is more "bolted on OOP" since there are quite a few different libraries that build OOP for it.
Re: Duktape: an embeddable JavaScript engine
#30If this is embedded in C++ I feel like you would be manipulating objects in the JavaScript scripts. JavaScript has OOP bolted on and it is not nearly as nice as Lua or similar alternatives. Why would a developer embed a JavaScript engine compared to something already existing?
Probably because Lua is horrible and JavaScript is awesome. Also npmjs.