You are browsing as a guest. Sign up (or log in) to start making projects!

Personal Site + Backend

  • 1 Devlogs
  • 7 Total hours

A personal landing site + a custom rust backend

Ship #1

Made a personal website, and more crucially its backend (in rust btw).
Particularly fun was navigating clippy on the strictest lint settings for the first time, which had me discarding a lot of bad practices i’ve implemented before, and (maybe) learning new bad habits to replace them :3
Really liked hacking together a system to fulfill specifically my own purposes, and the delightful refrain of “out of scope” every time something threatened to lure me into the Torment Hole.
Maybe i’ll work on this more at a later date but it’s fulfilled all the requirements i started with so im happy to ship

  • 1 devlog
  • 7h
Try project → See source code →
Open comments for this post

6h 56m 30s logged

Devlog #1: uuh…. done, I guess?

OK so full disclosure: this wasn’t initially going to be a stardance project. To be perfectly honest, I’d forgotten hackclub existed until I got their weekly email, and then I realised I could retroactively submit this here.
So, here it is: a custom rust server that supports not just the custom & kinda funky website I built, but also runs a multiplayer server for my as-yet unfinished game Particles, a boardgame I built based on a (no offense) kinda crummy mobile app, a writeup from the two thousands for a now inaccessible windows game, and a footnote of a game in one of those ad-riddled ‘unblocked games’ websites that my sister showed me. I may go into more depth about that game as another project, but for now I’ll only talk about the server.
It’s pretty simple, to be honest: since I made it for me and my close friends, I felt no need whatsoever to try and verify the integrity of the game. There’s no anticheat, no simulation of results: all it does is handle lobbies (plaintext json files with a uuid for a name) and players (single-use UUIDs assigned on joining a lobby). All exploration of state, validation of moves, and win checking is handled on the client side.
If one of my friends exploits this system, it’s going to be very funny, and I can’t wait to see how they do. Until then, everything else can happen on the client side. All the server needs to do is manage https requests.
The static site is, amusingly a little more complex.
Inspired by friends like circulars, carmine cassie, and ravarcheon whose websites are relatively simple and yet, it seems to me, contain a piece of their souls that feels unique and delightful, the core purpose of this site is to incite a single moment of delight.
Or amusement.
I’d take a raised eyebrow, to be honest.
Look, I’m not a frontend developer. I kinda suck at visual design, and my website isn’t going to be labeled ‘pretty’ or ‘elegant’.
What I am is creative, and a bit of a sneak. I’m someone who likes puzzles. I’m someone who likes surprising my friends. And I’m someone who’s willing to offer an objectively worse experience to the masses in order to create a cool experience for the people who found it.
I’m not going to go into depth about what my ‘trick’ is here. It’s hardly a challenging riddle (in fact, I might revise it at some point to increase the challenge), but it is Neat and it provides the little jolt of excitement i’m looking for. And, crucially, while I didn’t want to use a full web framework like Actix, it required more complexity than just serving the path requested.
Thus, I designed a system based around a manifest.json file. It contains a dictionary, where each key is the path requested, and each value is another dictionary containing a few pieces of information such as filepath, Mime type, and… well, if you’re curious take a peek for yourself! (Do try and figure out the trick with the website before you look at the answers, though.)
anyways: i use the tiny_http crate to handle incoming requests, partially because i don’t wanna figure out certificates on my own, and partially because having requests as a struct is really handy.
Then there’s the final element of the trick: the HTML part. Without saying too much, it’s two similar pages with different css and then an SVG clipping mask :3
Hope people like it !!

0
0
4

Delete project?

Are you sure you want to permanently delete this project? This action cannot be undone.

All devlogs, followers, and associated data will be removed.

Followers

Loading…