itself

0.1.0 • Public • Published

itself

A damn simple library to help you write shorter functions:

Instead of this:

var oddTaskNames = tasks
        .filter(function(task) { return task.number % 2 == 0 }).map
        .map(function(task) { return task.name })

Or this using it.js

var It = require('it.js')
var oddTaskNames = tasks
        .filter(It.get('number')['%'](2)['=='](0))
        .map(It.get('name'))

You can use this module, itself!

var itself = its = require('itself'), its
var oddTaskNames = tasks
        .filter(its('.number % 2 == 0'))
        .map(its('.name'))

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i itself

      Weekly Downloads

      2

      Version

      0.1.0

      License

      WTFPL

      Last publish

      Collaborators

      • dtinth