Chris Hayes :: hayes.software {
e.preventDefault()
fetch('/images/dragon.svg')
.then(response => response.text())
.then(svg => {
// Create a temporary element to hold the SVG
const temp = document.createElement('div')
temp.innerHTML = svg
// Get the SVG element
const svgElement = temp.querySelector('svg')
// Add a class to the SVG element
svgElement.classList.add('svg-class')
// Get the SVG as a string
const svgString = new XMLSerializer().serializeToString(svgElement)
// Copy the SVG to the clipboard
navigator.clipboard.writeText(svgString)
// Close the dropdown
close($refs.button)
})
}" class="flex w-full items-center gap-2 px-4 py-2.5 text-left text-sm first-of-type:rounded-t-md last-of-type:rounded-b-md hover:bg-primary hover:text-white focus:bg-primary focus:text-white">Copy SVG View on OpenMoji More emojis from Selina BauderScreenshot of the 3D Cubefield game scene Screenshot of the 3D Cubefield game scene Recreating a Classic: Cubefield in Three.JS Remember the days when flash games were all the rage? I certainly do. Taking a trip down memory lane led to my rendition of the classic game 'Cubefield', rebuilt with Three.js.
This was done back in 2017, so THREE.js may look a bit different today if you're looking at the code.
đŽ Play the game here: Cubefield
đ¨âđģ Check out the code on GitHub .
`;
showVideo = true;" x-show="showImage || showVideo" x-trap="showImage || showVideo" class="fixed top-0 left-0 z-50 h-full w-full bg-black bg-opacity-50 p-16" style="display:none" @click="showImage = false; showVideo = false">
close đī¸ This project was developed in 2017 or earlier, so it may use Three.js methods that have since been updated or deprecated.Edit this page on github .