Giter Site home page Giter Site logo

automail.js's Introduction

AUTOMAIL JS Build Status

Automail JS is a prototype extension for js lang

Installation

  • Bower bower install -S automail

Table of extended Functions

  1. Array
  2. String

Array

  • contains
console.log([1,2,3].contains(2)); // => true
console.log([1,2,3].contains(9)); // => false
  • first
console.log([1,2,3].first()); // => 1
console.log([].first()); // => null
  • last
console.log([1,2,3].last()); // => 3
console.log([].last()); // => null
  • size
console.log([1,2,3].size()); // => 3
console.log([].size()); // => 0
  • isEmpty
console.log([1,2,3].isEmpty()); // => false
console.log([].isEmpty()); // => true
  • removeAt
var array = [1,2,3];
console.log(array.removeAt(1)); // => 2
console.log(array); // => [1,3]
  • remove
var array = [1,2,3];
console.log(array.remove(2)); // => 2
console.log(array); // => [1,3]

⬆ back to top

String

  • contains
console.log('automail'.contains('mail')); // => true
console.log('autoMail'.contains('mail')); // => false

// case insensitive
console.log('autoMail'.contains('mail', true)); // => true
  • capitalize
console.log('automail'.capitalize()); // => 'Automail'
  • startsWith
console.log('automail'.startsWith('auto')); // => true
console.log('AutoMail'.startsWith('auto')); // => false

// case insensitive
console.log('AutoMail'.startsWith('auto', true)); // => true

⬆ back to top

automail.js's People

Contributors

dvbeato avatar gpedro avatar

Stargazers

Diego Henrique Domingues avatar

Watchers

James Cloos avatar

Forkers

gpedro

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.