Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/adamghill/unsuckjs.com
Progressively enhance HTML with lightweight JavaScript libraries.
https://github.com/adamghill/unsuckjs.com
ajax html javascript
Last synced: 13 days ago
JSON representation
Progressively enhance HTML with lightweight JavaScript libraries.
- Host: GitHub
- URL: https://github.com/adamghill/unsuckjs.com
- Owner: adamghill
- License: mit
- Created: 2021-07-20T12:40:12.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-07-31T11:44:50.000Z (3 months ago)
- Last Synced: 2024-10-15T02:05:46.734Z (25 days ago)
- Topics: ajax, html, javascript
- Language: HTML
- Homepage: https://unsuckjs.com
- Size: 181 KB
- Stars: 130
- Watchers: 5
- Forks: 24
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# unsuckjs.com
Progressively enhance HTML with lightweight JavaScript libraries. No build tools and no compiling necessary. Most libraries should be 10 KB or less (minified).
## ๐คจ Why?
Sometimes you don't need an entire SPA framework just to load a progress spinner.
## ๐ Shouldn't this just be an `awesome` repo?
Yeah, probably.
## ๐ ๏ธ Add a new library
1. Fork this repo
1. Update `data/libraries.json` following the current examples
1. Make a PR
1. ???
1. Profit!## ๐ค Why use `coltrane` to build this site?
unsuckjs.com looks like a static site (and it mostly is), but I wanted to fetch repository metadata dynamically without having to re-run a static site generator on a schedule. So, I used my personal static site framework, [coltrane](https://coltrane.readthedocs.io) to write most of the content in Markdown, but still have the flexibility of using Django `templatetags` for server-side functionality. It's the best of both worlds.
Also, because it's my site and I wanted to. ๐ฅน
## Hacker News Discussion
- https://news.ycombinator.com/item?id=36343544
## ๐ฌ Local development
1. `git clone` this repo
1. `cd` into the newly created directory
1. `uv install -r pyproject.toml`
1. Create a personal access token at https://github.com/settings/tokens
1. `cp .env.example .env`
1. Update `.env` with your GitHub username and personal access token that was just created
1. `uv run coltrane play`; note: this will take a while on the first load because it hits the GitHub API for every library individually## Minify CSS
1. `npm install -g uncss`
1. Make sure that the regular CSS files are enabled in the template
1. Make sure the site is running in another terminal
1. `uncss http://localhost:8000 --output site/static/css/unsuckjs.min.css -n`## Work with local coltrane
1. `source .venv/bin/activate`
1. `uv pip install -e ../coltrane/`
1. `coltrane play`