Skip to content
This repository has been archived by the owner on Aug 27, 2019. It is now read-only.

bodil/cljs-nashorn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cljs-nashorn

Provides a ClojureScript REPL running on Oracle's Nashorn Javascript engine.

Requirements

In order to run the Nashorn engine, you need a recent Java 8 runtime. This code was originally developed using version 1.8.0-ea-b75. It would be advisable to ensure you have at least this version installed.

Getting Java 8

Java 8 packages for various operating systems can be downloaded from Oracle's JDK8 download site.

Installing Java 8 on Ubuntu

At the time of writing, this is the easiest way to install a sufficiently recent Java 8 runtime on the Ubuntu GNU/Linux OS:

$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt-get install oracle-java8-installer

Leiningen Plugin

To setup the Leiningen plugin, add this to your project.clj or ~/.lein/profiles.clj:

:plugins [[org.bodil/lein-nashorn "0.1.2"]]

Then, start the REPL like this:

$ lein trampoline nasrepl

In-Project Usage

Add the following dependency to your project.clj:

[org.bodil/cljs-nashorn "0.1.2"]

To launch the REPL the hard way, run lein repl and enter the following:

(require '[cljs.repl :as repl] '[cljs.repl.nashorn :as nashorn])
(repl/repl (nashorn/repl-env))

License

Copyright © 2013 Bodil Stokke.

Distributed under the Eclipse Public License, the same as Clojure.

About

ClojureScript REPL on Nashorn

Resources

Stars

Watchers

Forks

Packages

No packages published