GraalJS
No reviews yet
A JavaScript language library.
Community voices
Reviews
Click once to include, again to exclude, again to clear
No reviews yet. Be the first to review this project!
Get it on
Available Platforms
Compatibility
Supported Environments
About
Project Details
For authors
Embed Badge
If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.
Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.
Identifiers
Platform IDs
Resources
External Links
About
Description
GraalJS is a fast JavaScript language implementation built on top of GraalVM. It is ECMAScript-compliant, provides interoperability with Java and other Graal languages, common tooling, and, if run on the GraalVM JDK, provides the best performance with the Graal JIT compiler by default. You can also use GraalJS with Oracle JDK or OpenJDK.
This mod packages GraalJS to facilitate other mods using GraalJS without needing to package it separately.
This mod does not contain any active modifications. When used as a library, you only need to add the dependency using
implementation "dev.anye.mc:graaljs:1.21.x-24.2.1-1-Neo-all"
It includes an EasyJS class for easy invocation of GraalJS
LOGGER.info("1 + 1 = {}",EasyJS.NotSafe().runCode("1+1"));
You can also directly use GraalJS
static String JS_CODE = "(function myFun(param){console.log('Hello ' + param + ' from JS');})";
public static void main(String[] args) {
String who = args.length == 0 ? "World" : args[0];
System.out.println("Hello " + who + " from Java");
try (Context context = Context.create()) {
Value value = context.eval("js", JS_CODE);
value.execute(who);
}
}
Version number explanation: GraalJS-(Supported Minecraft version)-(GraalJS version)-(This mod version number)-(Mod loader identifier)-(Packaging type)
For example: GraalJS-1.21.x-24.2.1-1-Neo-lite
GraalJS: https://www.graalvm.org/javascript/
GraalJS Documentation: https://www.graalvm.org/reference-manual/js/
This project's GitHub: https://github.com/An-Mao/MC-GraalJS
----Attention----
· This is not an official GraalVM product. If you encounter non-code related issues, please contact me.
· When starting the game with a JDK that includes GraalJS (such as GraalVM), errors may occur. Please use the lite version in the attached files.
Any questions can be asked in github or contacted as below:
This mod packages GraalJS to facilitate other mods using GraalJS without needing to package it separately.
Version number explanation: GraalJS-(Supported Minecraft version)-(GraalJS version)-(This mod version number)-(Mod loader identifier)-(Packaging type)
For example: GraalJS-1.21.x-24.2.1-1-Neo-lite
GraalJS: https://www.graalvm.org/javascript/
GraalJS Documentation: https://www.graalvm.org/reference-manual/js/
This project's GitHub: https://github.com/An-Mao/MC-GraalJS
----Attention----
· This is not an official GraalVM product. If you encounter non-code related issues, please contact me.
· When starting the game with a JDK that includes GraalJS (such as GraalVM), errors may occur. Please use the lite version in the attached files.
Any questions can be asked in github or contacted as below:
Screenshots
Gallery
Versions
Files
Relations
Project Relations
More like this
Similar Mods
Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.
On ModDex
Community snapshot
By the numbers
Statistics
Want to reach Minecraft players?
We're looking for a server hosting partner to feature here and other parts of the site. Interested? Send us a message!
Get in touchGet it on
Available Platforms
On ModDex
Community snapshot
By the numbers
Statistics
Resources