What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-11-09 14:59:21
javascript create blob or data/image from image url
function convertImgToBase64URL(url, callback, outputFormat){ var img = new Image(); img.crossOrigin = 'Anonymous'; img.onload = function(){ var canvas = document.createElement('CANVAS'), ctx = canvas.getContext('2d'), dataURL; ... Add solution -
Javascript 2021-11-09 05:39:24
chrome bookmarklet copy text
// This needs to be minified (and prefixed) to work // I just put the full function here to better show what the code is doing // Use the bottom line of code and replace "Text To Copy" with your own // text and you're good to go! (function (t... Add solution -
Javascript 2021-11-08 14:53:34
load youtube iframe player api
// This code loads the IFrame Player API code asynchronously. var tag = document.createElement('script'); tag.src = "https://www.youtube.com/iframe_api"; var firstScriptTag = document.getElementsByTagName('script')[0]; firstScriptTag.parentNode.... Add solution -
Other 2021-11-08 14:31:16
Analytics Reporting API codepen
<!DOCTYPE html> <html> <head> <title>Embed API Demo</title> </head> <body> <!-- Step 1: Create the containing elements. --> <section id="auth-button"></section> <section id="... Add solution -
Javascript 2021-11-08 11:49:16
javascript insert sibling after
<!-- beforebegin --> <p> <!-- afterbegin --> foo <!-- beforeend --> </p> <!-- afterend --> var tempDiv = document.createElement('div'); paragraph.insertAdjacentElement('afterend', tempDiv); // inserted div after... Add solution -
Javascript 2021-11-07 17:32:17
js create div
document.body.onload = addElement; function addElement () { // create a new div element const newDiv = document.createElement("div"); // and give it some content const newContent = document.createTextNode("Hi there and greetings!&... Add solution
Best helpers
Holyeyeolo
+5
Auntkym
+5
Mostafa 36a2
+5
RoToRa
+5
Rodrigorgs
+5
Matt2507864
+5
Arnav Bose
+5
Waldrumpus
+5
TheShade
+5
Naigel
+5
Rev1.0
+5
Babak
+5
Ohhh
+5
Jeff Sours
+5
Jim Mourgos
+5
J. Marks
+5
Piquet
+5