File tree 2 files changed +39
-0
lines changed
2 files changed +39
-0
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,8 @@ name = "rustpython_wasm"
3
3
version = " 0.1.0"
4
4
authors = [
" Ryan Liddle <[email protected] >" ]
5
5
license = " MIT"
6
+ description = " A Python-3 (CPython >= 3.5.0) Interpreter written in Rust, compiled to WASM"
7
+ repository = " https://github.com/RustPython/RustPython/tree/master/wasm/lib"
6
8
7
9
[lib ]
8
10
crate-type = [" cdylib" , " rlib" ]
Original file line number Diff line number Diff line change
1
+ # RustPython
2
+
3
+ A Python-3 (CPython >= 3.5.0) Interpreter written in Rust.
4
+
5
+ [ ![ Build Status] ( https://travis-ci.org/RustPython/RustPython.svg?branch=master )] ( https://travis-ci.org/RustPython/RustPython )
6
+ [ ![ License: MIT] ( https://img.shields.io/badge/License-MIT-green.svg )] ( https://opensource.org/licenses/MIT )
7
+ [ ![ Contributors] ( https://img.shields.io/github/contributors/RustPython/RustPython.svg )] ( https://github.com/RustPython/RustPython/graphs/contributors )
8
+ [ ![ Gitter] ( https://badges.gitter.im/RustPython/Lobby.svg )] ( https://gitter.im/rustpython/Lobby )
9
+
10
+ ## Usage
11
+
12
+ ### Check out our [ online demo] ( https://rustpython.github.io/demo/ ) running on WebAssembly.
13
+
14
+ ## Goals
15
+
16
+ - Full Python-3 environment entirely in Rust (not CPython bindings)
17
+ - A clean implementation without compatibility hacks
18
+
19
+ ## Quick Documentation
20
+
21
+ ``` js
22
+ pyEval (code, options);
23
+ ```
24
+
25
+ ` code ` : ` string ` : The Python code to run
26
+
27
+ ` options ` :
28
+
29
+ - ` vars ` : ` { [key: string]: any } ` : Variables passed to the VM that can be
30
+ accessed in Python with the variable ` js_vars ` . Functions do work, and
31
+ recieve the Python kwargs as the ` this ` argument.
32
+ - ` print ` : ` (out: string) => void ` : A function to replace the native print
33
+ function, by default ` console.log ` .
34
+
35
+ ## License
36
+
37
+ This project is licensed under the MIT license.
You can’t perform that action at this time.
0 commit comments