aboutsummaryrefslogtreecommitdiff
path: root/node_modules/ua-parser-js/readme.md
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2017-12-10 21:51:33 +0100
committerFlorian Dold <florian.dold@gmail.com>2017-12-10 21:51:33 +0100
commit0469abd4a9c9270a1fdc962969e36e63699af8b4 (patch)
treef9864d4a4148621378958794cbbfdc2393733283 /node_modules/ua-parser-js/readme.md
parent6947e79bbc258f7bc96af424ddb71a511f0c15a3 (diff)
upgrade dependencies
Diffstat (limited to 'node_modules/ua-parser-js/readme.md')
-rw-r--r--node_modules/ua-parser-js/readme.md18
1 files changed, 18 insertions, 0 deletions
diff --git a/node_modules/ua-parser-js/readme.md b/node_modules/ua-parser-js/readme.md
index da7bc48ba..9fe4025b5 100644
--- a/node_modules/ua-parser-js/readme.md
+++ b/node_modules/ua-parser-js/readme.md
@@ -212,6 +212,12 @@ requirejs(['ua-parser-js'], function(UAParser) {
});
```
+## Using CDN
+
+```html
+<script src="https://cdn.jsdelivr.net/npm/ua-parser-js@0/dist/ua-parser.min.js"></script>
+```
+
## Using bower
```sh
@@ -224,6 +230,18 @@ $ bower install ua-parser-js
$ meteor add faisalman:ua-parser-js
```
+## Using CLI
+
+```sh
+$ node ua-parser.min.js "Mozilla/4.0 (compatible; MSIE 4.01; Windows 98)"
+# multiple args
+$ node ua-parser.min.js "Opera/1.2" "Opera/3.4"
+# piped args
+$ echo "Opera/1.2" | node ua-parser.min.js
+# log file
+$ cat ua.log | node ua-parser.min.js
+```
+
## Using jQuery/Zepto ($.ua)
Although written in vanilla js (which means it doesn't depends on jQuery), this library will automatically detect if jQuery/Zepto is present and create `$.ua` object based on browser's user-agent (although in case you need, `window.UAParser` constructor is still present). To get/set user-agent you can use: `$.ua.get()` / `$.ua.set(uastring)`.