coffee-mate v0.16.2
CoffeeMate
Having CoffeeScript for Functional Programming is cool, and it will be much better with this CoffeeMate, which provides a lot of properties(which should be implemented by a library rather than the CS-compiler) for CSers, includes:
- log macro
- assert macro
- dict comprehension
- nested list comprehensions
- copy & deepcopy
- lazy evaluation
- type convertions
- string formating
- pseudo-random
- classic js object reinforcement
- funny & useful high-order functions for FPers.
API list
Here lists all APIs provided, click it to see demo. you can also read API description for more details.
type convertors:
int
,float
,bool
,str
,hex
,ord
,chr
,json
,obj
,url helpers:
uri_encoder
,uri_decoder
,lazy evaluation: here
basic functions:
flip
,seek
,pluck
,abs
,floor
,ceil
,sum
,max
,min
,max_index
,min_index
,next_permutation
,reinforce String:
a_string.format
,a_string.repeat
,reinforce Array:
an_array.first
,an_array.second
,an_array.third
,an_array.last
,reinforce Object:
Object.size
,Object.extend
,Object.update
,
Install
for nodejs
- install with npm:
your-repo/> npm install coffee-mate --save
- require separately or globally:
- require separately:
{log, assert, dict} = require 'coffee-mate'
- require globally:
require 'coffee-mate/global'
- require separately:
for browsers
<script src="http://rawgit.com/luochen1990/coffee-mate/master/build/global.js" type="text/javascript"></script>
Run Demo (nodejs)
run coffee ./demo.coffee
under directory coffee-mate/
directly after you have coffee-script
installed.
8 years ago
8 years ago
8 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago