API used to dynamically generate SVG and PNG Ludum Dare results badges in real-time.
Note: This project is community made and not endorsed by the offical Ludum Dare creator(s).
This monorepo is split up into the following packages:
- @ludum-dare-badges/api - Serveless API used to generate SVG & PNG badges
- @ludum-dare-badges/demo - Demo site used to showcase how to build a API query for a badge
- @ludum-dare-badges/react - React wrapper component which forms and calls the API based off passed props.
Simply form the API query using your game's Ludum Dare entry page path.
The path is in the form
event- Ludum Dare event number (eg.
44for Ludum Dare 44)
game- Game title in the URL of the Ludum Dare entry page.
type- File type. Can be either
svgis recommenced if it is supported.
For example the SVG badge for ALIEN, e x p a n s i o n .
the path would be
You can also think of it as adding
/badge.svg to the existing Ludum Dare path:
This path can be appended to the domain of
ldjam.tools to form the image URL:
Or more generalized:
badges.vandoorn.ca may also be used as the domain.
Self hosting can done easily though Now's serverless platform.
Simply install the Now CLI with:
yarn global add now
npm install -g now
now deploy in the root of the monorepo.
To form the API query follow the steps above with and replace the domain with the domain of your self hosted instance: