Skip to content

Commit 434d879

Browse files
committed
add main README
1 parent 97fd59c commit 434d879

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

README.md

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
2+
# MiniScript.TS
3+
4+
A MiniScript implementation written in TypeScript.
5+
6+
Works in the browser or on Node.js.
7+
8+
At the moment this project is not published either in a CDN for browser consumption nor as an NPM package to be used in Node.js. You will have to build locally.
9+
10+
## Building
11+
12+
You need to have Node.js installed in order to build the project. Version 19 or greater is recommended.
13+
14+
Start by installing all needed packages:
15+
16+
```
17+
npm install
18+
```
19+
20+
Then build with:
21+
22+
```
23+
npm run build
24+
```
25+
26+
This will create a `dist` folder with the following files:
27+
28+
* `miniscript-ts.mjs`: ECMAScript module for Node.js
29+
* `miniscript-ts.js`: [IIFE](https://developer.mozilla.org/en-US/docs/Glossary/IIFE#the_module_pattern) file for the browser
30+
* `miniscript-ts.d.ts`: TypeScript types
31+
* `miniscript-ts.cjs`: CommonJS module, should you need it
32+
* Map-files for each module type
33+
34+
## Usage on the browser
35+
36+
Consult the [examples/browser](examples/browser/) folder.
37+
38+
Note that you will need to build locally for the examples to work.
39+
40+
You will also need a local file-server if you want to open the examples on the browser.
41+
42+
## Usage on Node.js
43+
44+
Consult the [examples/nodejs](examples/browser/) folder.
45+
46+
Note that you will need to build locally for the examples to work.
47+
48+
## Acknowledgements
49+
50+
Many thanks to the amazing MiniScript community at Discord, for their encouragement during the development of this project.
51+
52+
Special thanks go to Joe Strout, author and creator of the MiniScript language and the Mini Micro programming environment. Without his generous help this project would not have been possible.

0 commit comments

Comments
 (0)