vue-cli-plugin-oembed
Advanced tools
Comparing version 1.0.2 to 1.0.3
{ | ||
"name": "vue-cli-plugin-oembed", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"private": false, | ||
@@ -5,0 +5,0 @@ "repository": "https://github.com/WhiteChocola/vue-cli-plugin-oembed", |
@@ -52,14 +52,16 @@ import axios from 'axios' | ||
let existingScript = document.getElementById('vue-tiktok-embed-script'); | ||
if(!existingScript){ | ||
let protocolToUse = 'https:' | ||
let s = document.createElement('script') | ||
s.async = s.defer = true; | ||
s.src = `${protocolToUse}//www.tiktok.com/embed.js` | ||
s.id = 'vue-tiktok-embed-script' | ||
const body = document.body | ||
if (body) { | ||
body.appendChild(s) | ||
} | ||
if(existingScript) | ||
existingScript.remove(); | ||
let protocolToUse = 'https:' | ||
let s = document.createElement('script') | ||
s.async = s.defer = true; | ||
s.src = `${protocolToUse}//lf16-tiktok-web.ttwstatic.com/obj/tiktok-web/tiktok/falcon/embed/embed_v1.0.10.js` | ||
s.id = 'vue-tiktok-embed-script' | ||
const body = document.body | ||
if (body) { | ||
body.appendChild(s) | ||
} | ||
}, | ||
} |
Sorry, the diff of this file is not supported yet
20966