mirror of
https://github.com/konvajs/konva.git
synced 2025-04-05 10:47:37 +08:00
fix CDN
This commit is contained in:
parent
ce4ced9a8e
commit
c76bbcd3e6
@ -23,7 +23,7 @@ This repository began as a GitHub fork of [ericdrowell/KineticJS](https://github
|
||||
# Quick Look
|
||||
|
||||
```html
|
||||
<script src="https://cdn.rawgit.com/konvajs/konva/2.4.1/konva.min.js"></script>
|
||||
<script src="https://unpkg.com/konva@2.4.1/konva.js"></script>
|
||||
<div id="container"></div>
|
||||
<script>
|
||||
var stage = new Konva.Stage({
|
||||
@ -68,10 +68,10 @@ Konva supports UMD loading. So you can use all possible variants to load the fra
|
||||
### 1 Load Konva via classical `<script>` tag:
|
||||
|
||||
```html
|
||||
<script src="https://cdn.rawgit.com/konvajs/konva/1.7.3/konva.min.js"></script>
|
||||
<script src="https://unpkg.com/konva@2.4.1/konva.js"></script>
|
||||
```
|
||||
|
||||
You can use CDN: [https://cdn.rawgit.com/konvajs/konva/1.7.3/konva.min.js](https://cdn.rawgit.com/konvajs/konva/1.7.3/konva.min.js)
|
||||
You can use CDN: [https://unpkg.com/konva@2.4.1/konva.js](https://unpkg.com/konva@2.4.1/konva.js)
|
||||
|
||||
### 2 Load via AMD (requirejs):
|
||||
|
||||
|
@ -4,11 +4,12 @@ set -e
|
||||
old_version="$(git describe --abbrev=0 --tags)"
|
||||
new_version=$1
|
||||
|
||||
old_cdn="https://cdn.rawgit.com/konvajs/konva/${old_version}/konva.js"
|
||||
new_cdn="https://cdn.rawgit.com/konvajs/konva/${new_version}/konva.js"
|
||||
|
||||
old_cdn_min="https://cdn.rawgit.com/konvajs/konva/${old_version}/konva.min.js"
|
||||
new_cdn_min="https://cdn.rawgit.com/konvajs/konva/${new_version}/konva.min.js"
|
||||
old_cdn="https://unpkg.com/konva@${old_version}/konva.js"
|
||||
new_cdn="https://unpkg.com/konva@${new_version}/konva.js"
|
||||
|
||||
old_cdn_min="https://unpkg.com/konva@${old_version}/konva.min.js"
|
||||
new_cdn_min="https://unpkg.com/konva@${old_version}/konva.min.js"
|
||||
|
||||
# make sure new version parameter is passed
|
||||
if [ -z "$1" ]
|
||||
|
Loading…
Reference in New Issue
Block a user