Getting Started with Feation
This page will help you get started with Feation. You'll be up and running in a jiffy!
Feation is a multi-paradigm, imperative, procedural, object-oriented, and beginner-friendly programming language that compiles to JavaScript. Feation is still in beta, but if you want to see the progress, you are free to clone the GitHub repository and play around with the code! Feation is influenced by languages such as Rust, Ruby, Go, and Swift. Just looking to install? Click here.
Example of what Feation will look like when completed:
# main car class.. #
class Car (manu, model) {
fn drive {
console.log("BRRRRRRRRRRRRR...")
}
}
var myCar = new Car("Jaguar", "F-Type")
var otherCar = new Car("Ferrari", "Daytona")
var allCars = [myCar, otherCar]
foreach (car in allCars) {
car.drive()
}
Another Alt-JS Language? Why?
There are a lot of programming languages that compile to JavaScript, some of the best being CoffeeScript, Spider and LiveScript. I never really liked the syntax of these languages, but Spider really stood out to me. After learning the Go programming language, I was almost instantly in love. I wanted to have a syntactically similar language to Go. Previously, I had created an award-winning programming language for a science fair called Pallet and didn't like the fact that the parser & lexer were generated, as I couldn't quite add features I really wanted to add. Pallet's source code became messy and unorganized, where it was hard to change anything without something else in the code breaking. I wanted to reincarnate Pallet as Feation, with a hand-written parser, lexer, and abstract syntax tree.
Installation
The Feation programming language is written in JavaScript on Ubuntu 14.04, but will run on any JavaScript environment, most recommended of which is NodeJS. Feation is not available on NPM at the moment.
Download/clone this repository, cd to the cloned directory, and type npm install -g. Installation with NPM will require NodeJS.
Quick-start for Linux users:
$ git clone https://github.com/Feation/Feation.git
$ cd Feation
$ sudo npm install -g
Usage
$ fea -h
Usage: fea [options] <files ...>
Options:
-h, --help output usage information
-V, --version output the version number
-r, --run runs program without outputting generated code
-o, --output outputs the generated code
Example: $ fea -o -r files/file.fea
Updated less than a minute ago
