Skip to content

Commit

Permalink
Remove duplicate maven coordinates in Java Interop docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
woess committed Sep 26, 2024
1 parent fca9dc4 commit e080304
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 18 deletions.
18 changes: 1 addition & 17 deletions docs/user/JavaInteroperability.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,7 @@ This documentation shows you how to enable interoperability with Java and possib

As of GraalVM for JDK 21, all necessary artifacts can be downloaded directly from Maven Central.
All artifacts relevant to embedders can be found in the Maven dependency group [`org.graalvm.polyglot`](https://central.sonatype.com/namespace/org.graalvm.polyglot).

To embed JavaScript in a Java application, add the following dependencies to the Maven configuration file:
```xml
<dependency>
<groupId>org.graalvm.polyglot</groupId>
<artifactId>polyglot</artifactId>
<version>${graaljs.version}</version>
</dependency>
<dependency>
<groupId>org.graalvm.polyglot</groupId>
<artifactId>js</artifactId>
<version>${graaljs.version}</version>
<type>pom</type>
</dependency>
```
The `pom` type is a requirement for a language dependency.
Learn more about the dependency setup in the [Java Interoperability guide](JavaInteroperability.md).
Learn more about the dependency setup in the [Getting Started guide](README.md).

## Polyglot Context

Expand Down
2 changes: 1 addition & 1 deletion docs/user/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Below is the Maven configuration for a JavaScript embedding:
</dependency>
```
This enables GraalJS which is built on top of Oracle GraalVM and licensed under the [GraalVM Free Terms and Conditions (GFTC)](https://www.oracle.com/downloads/licenses/graal-free-license.html).
Use `js-community` if you want to use GraalJS built on GraalVM Community Edition.
Use _artifactId_ `js-community` instead of `js` if you want to use GraalJS built on GraalVM Community Edition.

Go step-by-step to create a Maven project, embedding JavaScript in Java, and run it.
This example application was tested with GraalVM for JDK 23 and the GraalVM Polyglot API version 24.1.0.
Expand Down

0 comments on commit e080304

Please sign in to comment.