Git Product home page Git Product logo

hyec / javet Goto Github PK

View Code? Open in Web Editor NEW

This project forked from caoccao/javet

0.0 1.0 0.0 5.98 MB

Javet is Java + V8 (JAVa + V + EighT). It is an awesome way of embedding Node.js and V8 in Java.

Home Page: https://www.caoccao.com/Javet/

License: Apache License 2.0

Kotlin 0.41% CMake 0.79% Batchfile 0.06% Shell 0.10% C++ 13.97% C 0.63% JavaScript 0.91% Python 1.16% Java 80.92% TypeScript 0.01% Dockerfile 1.03%

javet's Introduction

Javet

Maven Central Discord Donate

Linux Build Android Build

Javet is Java + V8 (JAVa + V + EighT). It is an awesome way of embedding Node.js and V8 in Java.

If you like my work, please Star this project. And, you may follow me @sjtucaocao, or visit http://caoccao.blogspot.com/. And the official support channel is at discord.

💖 If you use Mac OS (x86_64), please be aware that the Mac OS (x86_64) build will discontinue anytime because my MacBook Air mid-2012 will be soon deprecated by new version of V8. Please donate to support me purchasing a new Mac OS (x86_64) device. Or, if you have a retired Mac OS (x86_64) device and are fine with mailing it to me, that will also be great. Thank you for supporting Javet. There is no new official releases after v1.1.0. Please contact the maintainer for the new private releases.

💖 If you use Mac OS (arm64), there is no new releases after v1.1.0. That's because I don't have any Mac OS (arm64) device to produce any new builds. Please donate to support me purchasing a new Mac OS (arm64) device.

Major Features

  • Linux (x86_64) + Mac OS (x86_64, arm64) + ️Windows (x86_64)
  • Android (arm, arm64, x86 and x86_64)
  • Node.js v16.15.1 + V8 v10.3.174.14
  • Dynamic switch between Node.js and V8 mode (Which mode do you prefer?)
  • Polyfill V8 mode with Javenode
  • V8 API exposure in JVM
  • JavaScript and Java interop
  • Native BigInt and Date
  • Javet engine pool
  • Easy spring integration
  • Live debug with Chrome DevTools

Quick Start

Dependency

Maven

<!-- Linux and Windows (x86_64) -->
<dependency>
    <groupId>com.caoccao.javet</groupId>
    <artifactId>javet</artifactId>
    <version>1.1.5</version>
</dependency>

<!-- Mac OS (x86_64 and arm64) -->
<dependency>
    <groupId>com.caoccao.javet</groupId>
    <artifactId>javet-macos</artifactId>
    <version>1.1.0</version>
</dependency>

Gradle Kotlin DSL

implementation("com.caoccao.javet:javet:1.1.5") // Linux and Windows (x86_64)
implementation("com.caoccao.javet:javet-macos:1.1.0") // Mac OS (x86_64 and arm64)
implementation("com.caoccao.javet:javet-android:1.1.5") // Android (arm, arm64, x86 and x86_64)

Gradle Groovy DSL

implementation 'com.caoccao.javet:javet:1.1.5' // Linux and Windows (x86_64)
implementation 'com.caoccao.javet:javet-macos:1.1.0' // Mac OS (x86_64 and arm64)
implementation 'com.caoccao.javet:javet-android:1.1.5' // Android (arm, arm64, x86 and x86_64)

Hello Javet

// Node.js Mode
try (V8Runtime v8Runtime = V8Host.getNodeInstance().createV8Runtime()) {
    System.out.println(v8Runtime.getExecutor("'Hello Javet'").executeString());
}

// V8 Mode
try (V8Runtime v8Runtime = V8Host.getV8Instance().createV8Runtime()) {
    System.out.println(v8Runtime.getExecutor("'Hello Javet'").executeString());
}

License

APACHE LICENSE, VERSION 2.0.

Documents

javet's People

Contributors

caoccao avatar cormanz avatar mowmowkittycat avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.