https://github.com/afaur/haxe-mithril
https://github.com/afaur/haxe-mithril
Last synced: 12 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/afaur/haxe-mithril
- Owner: afaur
- Created: 2016-03-14T18:10:11.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-03-18T02:19:38.000Z (over 10 years ago)
- Last Synced: 2025-02-12T13:56:55.379Z (over 1 year ago)
- Language: JavaScript
- Size: 3.91 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# What is this project
This is a very basic example project for building a [Mithril](http://mithril.js.org/) application with [Haxe](http://haxe.org/).
# Getting started
Download Haxe [here](http://haxe.org/download/)
Then run the `haxelib setup` command.
Here is an example:
```
// Haxe Does not understand ~ so you must specify the dir absolutely.
// Also using .haxelib doesn't seem to work properly as of now.
// Replace `username` below with your system user
haxelib setup /Users/username/haxelib
```
# Download dependencies
This is so we can run our tests.
```
haxelib install buddy
```
This is so we can build [Mithril](http://mithril.js.org/) apps
```
haxelib install mithril
```
# Compile and inspect
After that you should be able to `git clone` this project and then run: `./compile`
Then visit `http://localhost:2000` to view.
---
> `compile` is just a bash script that runs `haxe build.hxml`
> For more information on `build.hxml` look here:
> - http://old.haxe.org/doc/compiler
The `build.hxml` file tells the compiler to:
- Find the source files inside `src`
- Create a `app.js` file in the `build` directory.
The `./clean` bash script will clean out the build directory.
Try changing the build target by using the other options found at:
- http://haxe.org/documentation/introduction/compiler-usage.html
# Running tests
Right now there is only one test but it can be run using: `./check`