mod-lang-nashorn

JavaScript language module which uses Nashorn JS engine

License

License

Categories

Categories

JavaScript Languages
GroupId

GroupId

io.vertx
ArtifactId

ArtifactId

lang-nashorn
Last Version

Last Version

1.0.0-beta2
Release Date

Release Date

Type

Type

jar
Description

Description

mod-lang-nashorn
JavaScript language module which uses Nashorn JS engine
Project URL

Project URL

https://github.com/vert-x/mod-lang-nashorn
Source Code Management

Source Code Management

https://github.com/vert-x/mod-lang-nashorn

Download lang-nashorn

How to add to project

<!-- https://jarcasting.com/artifacts/io.vertx/lang-nashorn/ -->
<dependency>
    <groupId>io.vertx</groupId>
    <artifactId>lang-nashorn</artifactId>
    <version>1.0.0-beta2</version>
</dependency>
// https://jarcasting.com/artifacts/io.vertx/lang-nashorn/
implementation 'io.vertx:lang-nashorn:1.0.0-beta2'
// https://jarcasting.com/artifacts/io.vertx/lang-nashorn/
implementation ("io.vertx:lang-nashorn:1.0.0-beta2")
'io.vertx:lang-nashorn:jar:1.0.0-beta2'
<dependency org="io.vertx" name="lang-nashorn" rev="1.0.0-beta2">
  <artifact name="lang-nashorn" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.vertx', module='lang-nashorn', version='1.0.0-beta2')
)
libraryDependencies += "io.vertx" % "lang-nashorn" % "1.0.0-beta2"
[io.vertx/lang-nashorn "1.0.0-beta2"]

Dependencies

test (2)

Group / Artifact Type Version
junit : junit jar 4.10
io.vertx : testtools jar 2.0.3-final

Project Modules

There are no modules declared in this project.

Vert.x 2.x is deprecated - use instead https://github.com/vert-x3/vertx-lang-js

Javascript on Vert.x with Nashorn

This module uses the Nashorn JavaScript engine to power Vert.x JavaScript verticles This language module uses the generic vert.x Javascript API in mod-lang-js. The API documentation is the same as for lang-js and lang-rhino, and can be found on the lang-js CI server.

API Documentation

This module also supports CoffeeScript.

  • Important note. The Nashorn engine is an intrinsic part of the Java 8 JDK implementation. In order to use this module you will need to be running Vert.x with JDK 1.8.0 or later *

Usage

By default, vert.x runs Javascript with Rhino. Change this by creating a langs.properties file at the root of your project that looks something like this.

nashorn=io.vertx~lang-nashorn~0.1-SNAPSHOT:org.vertx.java.platform.impl.NashornVerticleFactory
.js=nashorn
.coffee=nashorn
io.vertx

vert.x

Legacy Vert.x 2.x - use instead Vert.x 3 instead https://github.com/eclipse/vert.x

Versions

Version
1.0.0-beta2
1.0.0-beta1