2.0.0 • Published 8 years ago

is-url-umd v2.0.0

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

is-url-amd

npm version

Tells you that string is in URL format. Library in UMD style.

Install

npm install is-url-umd

Usage

var isURL = require('is-url-umd');

if (isURL(string)) {
    console.log('it is string :)');
} else {
    console.log('this is not a string :(');
}

How it works?

In package is-url we can find run function .test() on RegExp:

/^(?:\w+:)?\/\/([^\s\.]+\.\S{2}|localhost[\:?\d]*)\S*$/

... and it is returns boolean.

Support

Library in UMD format, so support all kinds of exports:

  • AMD
  • CommonJS
  • typical global variable

Dependencies

Use https://www.npmjs.com/package/is-url to support isURL function.

2.0.0

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago