Skip to content

🖼️ An attempt to replicate GitHub's default profile pictures in TypeScript using Fastify and Canvas

License

Notifications You must be signed in to change notification settings

WaviestBalloon/github-pfp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

github-pfp

An attempt to replicate GitHub's default profile pictures in under 100 lines (excluding junk) using Fastify and Canvas

Installation

  1. Clone the repository
  2. Run npm i to install dependencies
  3. Run ./start.sh to transpile and start the server

Usage

Go to the root of the server (default: localhost:3000) for usage instructions after running the server

  • name - The text to base the profile picture on
  • mag - Image magnification of the output image
  • wh - Width and Height value of the output image
  • colour - Hexadecimal colour code for the pixels of the output image (Without #, e.g. ?colour=e8c8e8)

Examples

(gitpfp.wav.blue/pfp?mag=1) (gitpfp.wav.blue/pfp?mag=1&wh=50) (gitpfp.wav.blue/pfp?mag=1&wh=100)

Resources

  • GitHub for really cool profile pictures
  • GitHub Co-Pilot for holding my hand with the super complex mathamatical stuff
  • United States Naval Academy for the name list sample (fillernames.txt)

About

🖼️ An attempt to replicate GitHub's default profile pictures in TypeScript using Fastify and Canvas

Topics

Resources

License

Stars

Watchers

Forks