The (aspirational) foundation of CS at WCU!

Better Static Assets #76

Open bwc9876.dev
targeting ben/assignment-api from ben/better-static
Open opened by and assigned to bwc9876.dev
targeting ben/assignment-api from ben/better-static
  • Assets are now put in pkgs/web-assets/src and are bundled with Vite.
  • The just dev recipe now also runs a Vite dev server with HMR
  • inline-assets builds now need ASSET_DIST_DIR set to the path to the bundle
  • We'll need to set up something with Nix for this, won't be that bad
  • Puts inlining assets behind a feature (inline-assets)
    • Without this it'll assume a Vite dev server is running, idk how to feel abt that. I might make another feature and require either to be selected.
  • Also uses memory-serve to serve assets compressed
Commits 8

top: serve assets with memory-serve
web-assets: set lightningcss targets
treewide: use symlink for askama config
web-assets: init
assignments,db,cli: add manual_score options to assignments
assignments: use enclosed_name for ZIP handling
assignments: add example submission check
assignments: use saturating logic for summing scores