You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+9-8Lines changed: 9 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -79,14 +79,14 @@ See the [About Page](http://medialize.github.io/URI.js/) and [API Docs](http://m
79
79
80
80
URI.js (without plugins) has a gzipped weight of about 7KB - if you include all extensions you end up at about 13KB. So unless you *need* second level domain support and use URI templates, we suggest you don't include them in your build. If you don't need a full featured URI mangler, it may be worth looking into the much smaller parser-only alternatives [listed below](#alternatives).
81
81
82
-
URI.js is available through [npm](http://npmjs.org/), [bower](http://bower.io/) and manually from the [build page](http://medialize.github.io/URI.js/build.html):
82
+
URI.js is available through [npm](https://www.npmjs.com/package/urijs), [bower](http://bower.io/search/?q=urijs), [cdnjs](https://cdnjs.com/libraries/URI.js) and manually from the [build page](http://medialize.github.io/URI.js/build.html):
83
83
84
84
```bash
85
85
# using bower
86
86
bower install uri.js
87
87
88
88
# using npm
89
-
npm install URIjs
89
+
npm install urijs
90
90
```
91
91
92
92
### Browser ###
@@ -95,13 +95,13 @@ I guess you'll manage to use the [build tool](http://medialize.github.io/URI.js/
95
95
96
96
### Node.js and NPM ###
97
97
98
-
Install with `npm install URIjs` or add `"URIjs"` to the dependencies in your `package.json`.
98
+
Install with `npm install urijs` or add `"urijs"` to the dependencies in your `package.json`.
99
99
100
100
```javascript
101
101
// load URI.js
102
-
varURI=require('URIjs');
102
+
varURI=require('urijs');
103
103
// load an optional module (e.g. URITemplate)
104
-
var URITemplate =require('URIjs/src/URITemplate');
104
+
var URITemplate =require('urijs/src/URITemplate');
105
105
106
106
URI("/foo/bar/baz.html")
107
107
.relativeTo("/foo/bar/sub/world.html")
@@ -115,14 +115,14 @@ Clone the URI.js repository or use a package manager to get URI.js into your pro
115
115
```javascript
116
116
require.config({
117
117
paths: {
118
-
URIjs:'where-you-put-uri.js/src'
118
+
urijs:'where-you-put-uri.js/src'
119
119
}
120
120
});
121
121
122
-
require(['URIjs/URI'], function(URI) {
122
+
require(['urijs/URI'], function(URI) {
123
123
console.log("URI.js and dependencies: ", URI("//amazon.co.uk").is('sld') ?'loaded':'failed');
console.log("URITemplate.js and dependencies: ", URITemplate._cache?'loaded':'failed');
127
127
});
128
128
```
@@ -242,6 +242,7 @@ URI.js is published under the [MIT license](http://www.opensource.org/licenses/m
242
242
243
243
Package Management Cleanup - no changes to source code!
244
244
245
+
* renaming package to "urijs", was "URIjs" (because npm decided to go lower-case at some point and maintaining capitals in your package name poses all sorts of stupid issues)
245
246
* removing [jam](http://jamjs.org/), [spm](http://spmjs.org/), `component.json` and `URI.jquery.json` as nobody cared that URI.js was stuck on 1.14 for a year
0 commit comments