0.3.0 • Published 6 years ago

@lvchengbin/url v0.3.0

Weekly downloads
93
License
MIT
Repository
github
Last release
6 years ago

URL

Polyfill for URL and URLSearchParams. Totally following the implementation of Google Chrome.

Installation

$ npm i @lvchengbin/url --save

Usage

const { URL, URLSearchParams } = require( '@lvchengbin/url' );

ES6

import { URL, URLSearchParams } from '@lvchengbin/url';

Loading with <SCRIPT> tag

If you want to use this library in browsers and to load it with <SCRIPT> tag, you should use url.js, and if you want to use the library in browsers which do not support ES6 syntax, you should use url.bc.js instead.

<script src="./url.bc.js"></script>
<script>
    var url = new JURL.URL( 'http://www.google.com/path?x=1&y=2' );        
    var params = new JURL.URLSearchParams( 'x=1&y=2' );
    console.log( 'url', url );
    console.log( 'params', params );
</script>
0.3.0

6 years ago

0.2.1

7 years ago

0.2.0

7 years ago

0.1.8

7 years ago

0.1.7

7 years ago

0.1.6

7 years ago

0.1.5

7 years ago

0.1.4

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.6

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago