<script type="module">
import {reverse, split} from 'gifken'
const imageUrl = '/01_Koch-Kurve-Sechseck-alt._Def.-2.gif'
const response = await fetch(imageUrl)
const buffer = await response.arrayBuffer()
const results = await split(new Uint8Array(buffer))
for (const result of results) {
const img = new Image()
img.src = URL.createObjectURL(new Blob([result], {type: 'image/gif'}))
document.body.append(img)
}
</script>
const {readFileSync, writeFileSync} = require('fs')
const gifken = require('gifken')
gifken
.reverse(readFileSync('./assets/01_Koch-Kurve-Sechseck-alt._Def.-2.gif'))
.then(result => {
writeFileSync('reverse.gif', result)
})
To build gifken, following tools are required
git clone *thisrepo*
cd gifken
npm install
npm run build
MIT