Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/?q=image&page=606&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=image

Returns an array of strings in format "username" or "username/projectName"

Found 6268 results for "image"(1489ms)

thememain.tsx1 match

@shanberg•Updated 1 year ago
472 dimensions: "width, height",
473 position: "left, right, top, bottom",
474 background: "background-color, background-image, background-position",
475 },
476 easing: {

socialImageUsageCSSmain.tsx1 match

@tylergaw•Updated 1 year ago
1export const socialImageUsageCSS = `
2 * {
3 box-sizing: border-box;

textToImageDallemain.tsx2 matches

@hootz•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export const textToImageDalle = async (
4 openAIToken: string,
5 prompt: string,
13 }[];
14 } = await fetchJSON(
15 "https://api.openai.com/v1/images/generations",
16 {
17 method: "POST",

getWttrmain.tsx1 match

@LavaC•Updated 1 year ago
17 let response = await fetch(`https://wttr.in/${location}.png?lang=zh-cn&m&t`, {
18 headers: {
19 "Content-Type": "image/png",
20 "Accept-Language": "zh-cn",
21 },

upscaleThisUrlmain.tsx7 matches

@andrew•Updated 1 year ago
6 const url = "https://api.replicate.com/v1/predictions";
7 const jobId = req.body?.jobId;
8 const imageUrl = req.body?.imageUrl;
9 if (!jobId && !imageUrl) {
10 res.status(400).json({
11 error:
12 "You must pass either a jobId or an imageUrl. You did not pass either.",
13 });
14 }
15 if (jobId && imageUrl) {
16 res.status(400).json({
17 error:
18 "You must pass either a jobId or an imageUrl. You cannot pass both.",
19 });
20 }
21 if (imageUrl) {
22 const body = {
23 version:
24 "660d922d33153019e8c263a3bba265de882e7f4f70396546b6c9c8f9d47a021a",
25 input: {
26 image: imageUrl,
27 },
28 };

proxyJpegmain.tsx1 match

@steven•Updated 1 year ago
6 const blob = await response.arrayBuffer();
7 return new Response(blob, {
8 headers: { "Content-Type": "image/jpeg" },
9 });
10};

parsePdfDatamain.tsx2 matches

@speepo•Updated 1 year ago
39 console.log("got pdfData: ", { pdfData });
40 // Check if the PDF has fillable form data
41 const hasFormData = pdfData.formImage.Pages.some((page) =>
42 page.Fields.length > 0
43 );
48 }
49 // Extract the form data and send it as the response
50 const formData = pdfData.formImage.Fields;
51 res.json(formData);
52 })

artICGetRandommain.tsx4 matches

@wilt•Updated 1 year ago
13 "title",
14 "artist_title",
15 "image_id",
16 "date_display",
17 "thumbnail",
25 filter: [
26 { term: { is_public_domain: true } },
27 { exists: { field: "image_id" } },
28 { exists: { field: "thumbnail.alt_text" } },
29 ],
39 art: resp.data.map((item) => ({
40 ...item,
41 image_url:
42 `${resp.config.iiif_url}/${item.image_id}/full/843,/0/default.jpg`,
43 art_url: `${resp.config.website_url}/artworks/${item.id}`,
44 })),

hootsuiteNasamain.tsx4 matches

@stevekrouse•Updated 1 year ago
2
3export async function hootsuiteNasa(req: express.Request, res: express.Response) {
4 const NASA_ROOT = "https://images-api.nasa.gov";
5 const alphaNumericSpaces = new RegExp("^[a-zA-Z0-9\\s-_]+$");
6 const acceptableRedirectUri = new RegExp(
13 res.send('{"data":[],"metadata":{"cursor":{}}}');
14 }
15 var uri = NASA_ROOT + "/search?q=" + query + "&media_type=image";
16 if (req.query.cursor) {
17 uri = decodeURIComponent(req.query.cursor);
24 "id": results.collection.items[i].data[0].nasa_id,
25 "name": results.collection.items[i].data[0].title,
26 "mediaType": "Image",
27 "mimeType": "image/jpeg",
28 "original": {
29 "url": results.collection.items[i].links[0].href,

resumemain.tsx1 match

@ajax•Updated 1 year ago
7 "name": "Thomas Davis",
8 "label": "Web Developer",
9 "image": "https://avatars0.githubusercontent.com/u/416209?s=460&u=38f220a2c9c658141804f881c334c594eb1642ac&v=4",
10 "summary": "I'm a full stack web developer who can build apps from the ground up. I've worked mostly at startups so I am used to wearing many hats. I am a very product focussed developer who priotizes user feedback first and foremost. I'm generally very flexible when investigating new roles. ",
11 "website": "https://lordajax.com",

brainrot_image_gen1 file match

@dcm31•Updated 1 week ago
Generate images for Italian Brainrot characters using FAL AI

modifyImage2 file matches

@stevekrouse•Updated 1 week ago
Atiq
"Focal Lens with Atig Wazir" "Welcome to my photography journey! I'm Atiq Wazir, a passionate photographer capturing life's beauty one frame at a time. Explore my gallery for stunning images, behind-the-scenes stories, and tips & tricks to enhance your own