Search

Results include substring matches and semantically similar vals. Learn more
stevekrouse avatar
favFarm
@stevekrouse
Clone of fav.farm by @wesbos A little favicon service
HTTP
<h1>I bet you need a quick favicon</h1>
<p>
This startup returns an emoji inside an SVG<br />so you can pop that sucker into a favicon.
</p>
<p>
pomdtr avatar
markdocReactExample
@pomdtr
Markdoc Playground This readme is rendered using markdoc . {% val author="pomdtr" name="markdocReactExample" %}
HTTP
# [Markdoc Playground](https://pomdtr-markdocReactExample.web.val.run)
This readme is rendered using [markdoc](https://markdoc.dev/).
{% val author="pomdtr" name="markdocReactExample" %}
/** @jsxImportSource npm:react */
import { api } from "https://esm.town/v/pomdtr/api";
import Markdoc from "npm:@markdoc/markdoc";
import React from "npm:react";
import { renderToString } from "npm:react-dom/server";
const tags = {
return <iframe width="600" height="300" frameBorder="0" src={`https://www.val.town/embed/${author}/${name}`} />;
export async function markdocReactExample(req: Request) {
// extract the current val readme
const content = Markdoc.transform(ast, { tags }); // register the val tag
const rendered = Markdoc.renderers.react(content, React, {
components: {
manyone avatar
big5PersonalityTest
@manyone
An interactive, runnable TypeScript val by manyone
HTTP
lowTraits: ['Spontaneous', 'Flexible', 'Casual', 'Adaptable']
'Emotional Stability': {
al Stability measures an individual\'s ability to manage stress and emotional reactions. High scorers are calm, resilient, an
highTraits: ['Calm', 'Resilient', 'Even-tempered', 'Confident'],
lowTraits: ['Sensitive', 'Reactive', 'Anxious', 'Emotionally Variable']
'Intellect/Imagination': {
description: 'Intellect/Imagination reflects cognitive curiosity, creativity, and openness to new experiences.
all avatar
tomasoValmax
@all
@jsxImportSource https://esm.sh/react
HTTP
/** @jsxImportSource https://esm.sh/react */
import React, { useEffect, useRef, useState } from "https://esm.sh/react";
import { createRoot } from "https://esm.sh/react-dom/client";
function SoundMaker() {
</div>
function client() {
createRoot(document.getElementById("root")).render(<App />);
if (typeof document !== "undefined") {
client();
export default async function server(request: Request): Promise<Response> {
turbo1912 avatar
private_model
@turbo1912
@jsxImportSource https://esm.sh/react
Cron
/** @jsxImportSource https://esm.sh/react */
import fal from "npm:@fal-ai/serverless-client";
import { renderToString } from "npm:react-dom/server";
export default async function(interval: Interval) {
temptemp avatar
createMovieSite
@temptemp
// Utility function to generate movie poster URL
HTTP
} else {
modal.classList.add('hidden');
// Add click outside to close modal
modal.addEventListener('click', (event) => {
if (event.target === modal) {
isidentical avatar
falSDXLExample
@isidentical
An interactive, runnable TypeScript val by isidentical
Script
import * as fal from "npm:@fal-ai/serverless-client";
fal.config({
// Can also be auto-configured using environment variables:
pomdtr avatar
vanPlate
@pomdtr
Van Plate
HTTP
"area",
"article",
"aside",
"audio",
"b",
stevekrouse avatar
todo_app
@stevekrouse
@jsxImportSource https://esm.sh/react
HTTP
/** @jsxImportSource https://esm.sh/react */
import React from "https://esm.sh/react";
import { renderToString } from "https://esm.sh/react-dom@18.2.0/server";
import { sqlite } from "https://esm.town/v/std/sqlite?v=4";
billtrenchard avatar
todo_demo
@billtrenchard
@jsxImportSource https://esm.sh/react
HTTP
/** @jsxImportSource https://esm.sh/react */
import React from "https://esm.sh/react";
import { renderToString } from "https://esm.sh/react-dom@18.2.0/server";
import { sqlite } from "https://esm.town/v/std/sqlite?v=4";
dbee avatar
fcReady
@dbee
// Initialize the Farcaster SDK and set the frame context
Script
document.addEventListener("click", (event) => {
const target = event.target;
// Find the closest button if the click target is nested inside
const button = target.closest("button");
if (button) {
janpaul123 avatar
getValsContextWindow
@janpaul123
An interactive, runnable TypeScript val by janpaul123
Script
type: "http",
prompt: "Generate a val that uses React to render HTML",
code: `/** @jsxImportSource https://esm.sh/react */
import { renderToString } from "npm:react-dom/server";
export const reactExample = (request: Request) =>
new Response(renderToString(<div>Test {1 + 1}</div>), {
prompt: null,
code: `/** @jsxImportSource https://esm.sh/preact */
import { render } from "npm:preact-render-to-string";
export const preactExample = (request: Request) =>
new Response(render(<div>Test {1 + 1}</div>), {
type: "http",
code: `/** @jsxImportSource https://esm.sh/preact */
import { render } from "npm:preact-render-to-string";
export default async function(req: Request) {
stevekrouse avatar
date_me_faq
@stevekrouse
@jsxImportSource https://esm.sh/preact
Script
/** @jsxImportSource https://esm.sh/preact */
let linkClass = "text-sky-600 hover:text-sky-500";
export let date_me_faq = (
vawogbemi avatar
notUberHome
@vawogbemi
@jsxImportSource https://esm.sh/react@18.2.0
Script
/** @jsxImportSource https://esm.sh/react@18.2.0 */
import { SignedIn, SignedOut, SignInButton } from "https://esm.sh/@clerk/clerk-react?bundle-deps&deps=react@18.2.0";
import { IconCircleFilled, IconSquareFilled } from "https://esm.sh/@tabler/icons-react?deps=react@18.2.0";
import React, { useEffect, useState } from "https://esm.sh/react@18.2.0";
import { AutocompleteInput, MapComponent } from "https://esm.town/v/vawogbemi/notUberMapComponent";
mikehiggins avatar
lovelyYellowXerinae
@mikehiggins
// Expanded stopwords list with additional web-specific terms
Script
// Additional navigation-related terms
'back', 'contents', 'menu', 'home', 'next', 'previous', 'top', 'bottom', 'navigation', 'nav', 'sidebar', 'footer',
'header', 'main', 'article', 'section', 'page', 'skip', 'jump', 'return',
// Remove script, style, nav, header, footer, and other non-content elements
lementsToRemove = root.querySelectorAll('script, style, nav, header, footer, aside, .navigation, .menu, .sidebar, [role="navi
elementsToRemove.forEach(el => el.remove());
<p>TF-IDF (Term Frequency-Inverse Document Frequency) is a brilliant way to figure out how important a word or phrase
ween providing enough information and not overwhelming the user. It's also considered a "lucky" number in many cultures!</p>
<p class="source-link">
document.body.removeChild(tempTextArea);
// Client-side character count limit
inputText.addEventListener('input', function() {