A minimalist, deterministic daily-shuffling webring. The order of sites resets every midnight, ensuring everyone gets equal time at the "front" of the ring.
Why??
-> why not?
- Fork this repository.
- Add your site to
members.json:Note: Please include the trailing slash{ "name": "Your Name", "url": "https://your-site.com/", "description": "A brief blurb about your corner of the web." }/in your URL for consistent matching. - Submit a Pull Request. Our GitHub Action will automatically validate your JSON.
- Once merged, add the widget to your site.
Copy and paste this snippet into your HTML (usually in the footer):
<div id="webring"></div>
<script src="https://ringring.rajatdahal.com.np/webring.js"></script>Drop the snippet directly into your index.html.
Add the snippet to your footer partial or layout file.
<div id="webring"></div>
<script src="https://ringring.rajatdahal.com.np/webring.js"></script>Use useEffect to load the script safely. This version prevents duplicate script injection:
import { useEffect } from 'react';
export default function Webring() {
useEffect(() => {
const existingScript = document.querySelector('script[src*="ringring/webring.js"]');
if (!existingScript) {
const script = document.createElement('script');
script.src = "https://ringring.rajatdahal.com.np/webring.js";
script.async = true;
document.body.appendChild(script);
}
}, []);
return <div id="webring"></div>;
}The widget uses Shadow DOM, providing a "Ghost" UI that stays isolated from your site's styles.
- Adaptive Theme: It automatically detects
lightordarkmode via your browser'sprefers-color-scheme. - Font: Defaults to
IBM Plex Mono(if available) or system monospace. - Inheritance: It inherits the parent container's
colorandfont-sizefor a seamless fit.
To test the validation logic locally:
- Ensure you have Node.js installed.
- Run
node validate.js.
To test the widget locally:
- Add
http://localhost:8000/(or your local port) tomembers.json. - Run a local server:
python3 -m http.server 8000.