Browse Source

updating readme

pull/125/head
Jason Williams 5 years ago
parent
commit
48819b6801
  1. 43
      README.md

43
README.md

@ -1,19 +1,17 @@
### Boa ## Boa
This is an experimental Javascript lexer, parser and compiler written in Rust. Currently, it has support for some of the language. This is an experimental Javascript lexer, parser and compiler written in Rust. Currently, it has support for some of the language.
[![Build Status](https://travis-ci.com/jasonwilliams/boa.svg?branch=master)](https://travis-ci.com/jasonwilliams/boa) [![Build Status](https://travis-ci.com/jasonwilliams/boa.svg?branch=master)](https://travis-ci.com/jasonwilliams/boa)
[![](http://meritbadge.herokuapp.com/boa)](https://crates.io/crates/boa) [![](http://meritbadge.herokuapp.com/boa)](https://crates.io/crates/boa)
[![](https://docs.rs/Boa/badge.svg)](https://docs.rs/Boa/) [![](https://docs.rs/Boa/badge.svg)](https://docs.rs/Boa/)
This project is an attempted rewrite of Bebbington's js.rs. Most of the Rust code has been rewritten from scratch. ### Live Demo (WASM)
#### Live Demo (WASM)
https://jasonwilliams.github.io/boa/ https://jasonwilliams.github.io/boa/
You can get more verbose errors when running from the command line You can get more verbose errors when running from the command line
### Contributing ## Contributing
If you don't already have Rust installed rustup is the recommended tool to use. It will install Rust and allow you to switch between nightly, stable and beta. You can also install additional components. If you don't already have Rust installed rustup is the recommended tool to use. It will install Rust and allow you to switch between nightly, stable and beta. You can also install additional components.
@ -21,19 +19,31 @@ If you don't already have Rust installed rustup is the recommended tool to use.
curl https://sh.rustup.rs -sSf | sh curl https://sh.rustup.rs -sSf | sh
``` ```
Then simply clone this project and `cargo build` Then simply clone this project and `cargo build` inside the directory.
To develop on the web assembly side you can run `yarn serve` then go to `http://localhost:8080`
#### Debugging ### VSCode
See [Debugging](./docs/debugging.md) #### Plugins
Either the [Rust (RLS)](https://github.com/rust-lang/rls) or the [Rust Analyzer](https://github.com/rust-analyzer/rust-analyzer) extension is preferred. RLS is easier to set up but most of the development is moving towards Rust Analyzer.
Both of these plugins will help you with your Rust Development
#### Tasks
There are some pre-defined tasks in [tasks.json](.vscode/tasks.json)
#### VSCode and Dockerfile - Build - shift+cmd/ctrl+b should build and run cargo. You should be able to make changes and run this task.
- Test - (there is no shortcut, youll need to make one) - Runs `Cargo Test`.
I personally set a shortcut of shift+cmd+option+T (or shift+ctrl+alt+T)
If you don't want to install everything on your machine, you can use the Dockerfile. If you don't want to install everything on your machine, you can use the Dockerfile.
Start VSCode in container mode (you may need the docker container plugin) and use the Dockerfile. Start VSCode in container mode (you may need the docker container plugin) and use the Dockerfile.
#### Web Assembly ### Debugging
See [Debugging](./docs/debugging.md)
### Web Assembly
This interpreter can be exposed to javascript! This interpreter can be exposed to javascript!
You can build the example locally with: You can build the example locally with:
@ -44,12 +54,17 @@ $ yarn serve
``` ```
In the console you can use `window.evaluate` to pass JavaScript in In the console you can use `window.evaluate` to pass JavaScript in
To develop on the web assembly side you can run `yarn serve` then go to `http://localhost:8080`
## Roadmap
See Milestones
#### Roadmap ## Changelog
See Project view see [CHANGELOG](./CHANGELOG.md)
#### Usage ### Usage
- Checkout this project - Checkout this project
- Build `cargo build` - Build `cargo build`

Loading…
Cancel
Save