Git Product home page Git Product logo

checkpoint2-string-class's Introduction

Coverage Status Build Status

Checkpoint 2 String Class

About String Class

String class is an Andela checkpoint project that improves the native javascript String Object.

This Project is meant to add additional features to the String Object by extending it's prototype.

List Of New Methods Added.


  • hasVowels - Check to see if a string contains vowels

  • toUpper - Converts the string into uppercase

  • toLower - Converts the string into lowercase

  • ucFirst - Converts the first character of a string into uppercase

  • isQuestion - Check to see if a string is a question (ending with '?')

  • words - Return all words in a string as an array

  • wordCount - Counts and return the number of words in a string

  • toCurrency - Converts a string such as '11111` to currency format (11,111)

  • fromCurrency - Converts a string in currency format into a number e.g (11,111 -> 11111)

  • inverseCase - Return the string inverting the cases of its characters e.g ('AbC' -> 'aBc')

  • alternatingCase - Alternates cases of string characters starting with lowercase e.g ('hello' -> 'hElLo')

  • getMiddle - Return the middle character(s) in a string e.g ('ABCD' -> 'BC')

  • numberWords - Returns the numbers in a string in words e.g ('112' -> 'one one two')

  • isDigit - Returns true if a string is a single digit

  • doubleCheck - Returns true if a string contains double characters such as 'pp' in 'pappa'

How to install


  • Clone this repository:: - git clone [email protected]:andela-emurphy/checkpoint2-String-class.git

  • Change directory: - cd checkpoint2-String-class/test

  • Run - npm install

  • Run - bower install

  • Test - run npm test

Alternative Use


  • Add to your HTML script tag
  • Call the methods from your frontend web app

Technologies Used


  • Javascript (ES6)
  • Jasmine
  • Karma
  • Node.js

How to Contribute


  • Fork or clone the repo to your folder.
  • Change directory: cd checkpoint2-String-class
  • Run npm install
  • Create a feature branch and work on it.
  • Push to the remote branch.
  • Open a Pull Request to develop branch.

Limitations


The program does not run on all web browsers.

checkpoint2-string-class's People

Watchers

James Cloos avatar

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.