Public vals
13
g
countGithubLOCUI
HTTP
GitHub Line Counter π GitHub Line Counter , live on val.town ; Ever wondered how many lines of code are in a GitHub repo without the hassle of cloning it? Say hello to GitHub Line Counter β your friendly, web-based LOC inspector! π What It Does This simple tool fetches the GitHub repository as a ZIP file,
decompresses it on the fly (thanks to fflate π¨),
and counts the lines of code β on val.town
with an incredible bandwith and speed. Built with Vanilla JS on the frontend and
powered by val.town on the backend,
itβs lightweight, fast, and ready to use! How to Use Just paste the repo URL, hit "Count Lines," and watch the magic happen! β¨
2
g
ThumbMaker
HTTP
* This application creates a thumbnail maker using Hono for server-side routing and client-side JavaScript for image processing.
* It allows users to upload images, specify output options, and generate a composite thumbnail image.
* The app uses the HTML5 Canvas API for image manipulation and supports drag-and-drop functionality.
*
* The process is divided into two steps:
* 1. Generating thumbnails: Users choose thumbnail size options and create individual thumbnails.
* 2. Rendering: Users can create and export the final composite image with options for format and quality.
* This two-step process allows changing format or quality without re-rendering the entire canvas.
*
* Additional features:
* - Users can go back from the second step to the first one to regenerate thumbnails.
* - Dropping new files takes the user back to the first step.
* - A "Download Metadata" button is added to download a JSON file with thumbnail information.
0
g
serveUtils
Script
Serve Utils This val exports various utility functions, mainly the serve(commentFunction, contentType?) .
It enables easy serving of different files, while allowing the use of all string characters: // this is possible
const arr = ["Hello", 'world', `!`]; Townie Prompt This can be used as a replacement system prompt for Townie.
Townie will: Write client-side applications with vanilla JavaScript Serve them as different assets, ie. index.html , style.css and main.js Use modern module syntax, including importing modules directly from esm.sh on the client side Not reuse the same script for the server and client logic IMPORTANT: Due tue val.town README restrictions,
the custom prompt can now be found
here .
0