update cdn link, put browser first
This commit is contained in:
parent
de3f74a572
commit
8ddd8cd2f5
22
README.md
22
README.md
|
@ -58,7 +58,17 @@ utcDate.toISOString();
|
||||||
- 2.5kb Minified
|
- 2.5kb Minified
|
||||||
- <1kb `gzip`d
|
- <1kb `gzip`d
|
||||||
|
|
||||||
Compatible with Node.js & Browsers.
|
Compatible with Browsers, and Node.js.
|
||||||
|
|
||||||
|
## Browsers
|
||||||
|
|
||||||
|
```html
|
||||||
|
<script src="https://unpkg.com/xtz@latest/xtz.min.js"></script>
|
||||||
|
```
|
||||||
|
|
||||||
|
```js
|
||||||
|
var TZ = window.XTZ;
|
||||||
|
```
|
||||||
|
|
||||||
## Node.js & Webpack
|
## Node.js & Webpack
|
||||||
|
|
||||||
|
@ -70,16 +80,6 @@ npm install --save xtz
|
||||||
var TZ = require("xtz");
|
var TZ = require("xtz");
|
||||||
```
|
```
|
||||||
|
|
||||||
## Browsers
|
|
||||||
|
|
||||||
```html
|
|
||||||
<script src="https://unpkg.com/xtz@1.0.0-rc.1/xtz.min.js"></script>
|
|
||||||
```
|
|
||||||
|
|
||||||
```js
|
|
||||||
var TZ = window.XTZ;
|
|
||||||
```
|
|
||||||
|
|
||||||
# API
|
# API
|
||||||
|
|
||||||
- `toTimeZone(utcDate, timeZone)`
|
- `toTimeZone(utcDate, timeZone)`
|
||||||
|
|
Loading…
Reference in New Issue