sveltemeacoffee
v0.0.1
Published
Fully Configurable Buy Me A Coffee button in svelte
Downloads
56
Maintainers
Readme
sveltemeacoffee
Fully Configurable Buy Me A Coffee button in svelte
Why does this exist?
When trying to use the Buy Me A Coffee button, I noticed there are a few things wrong with the buttons you can create:
- There are only a handful of colored images to choose from.
- If you try to use a custom color or text, you can't get an image link for that custom value.
- If you try to use the script code they give you, it fails in Svelte/Kit (and maybe Nuxt, etc, as well)with the following error:
Failed to execute 'write' on 'Document': It isn't possible to write into a document from an asynchronously-loaded external script unless it is explicitly opened.
Options:
There are SVG images in the BMAC creator kit, so I used those to create a SVG image of the button and used the svg translate()
for scaling.