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/$%7Burl%7D?q=database&page=756&format=json

For typeahead suggestions, use the /typeahead endpoint:

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

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

Found 8416 results for "database"(4792ms)

OpenTowniethink.ts1 match

@nuloโ€ขUpdated 3 months ago
7export const thinkTool = tool({
8 description:
9 "Use the tool to think about something. It will not obtain new information or change the database, but just append the thought to the log. Use it when complex reasoning or some cache memory is needed.",
10 parameters: z.object({
11 thought: z.string().describe("A thought to think about."),

OpenTowniesystem_prompt.txt2 matches

@nuloโ€ขUpdated 3 months ago
149```
150โ”œโ”€โ”€ backend/
151โ”‚ โ”œโ”€โ”€ database/
152โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Schema definitions
153โ”‚ โ”‚ โ”œโ”€โ”€ queries.ts # DB query functions
208 ```
209
210### Database Patterns
211- Run migrations on startup or comment out for performance
212- Change table names when modifying schemas rather than altering

reactRouter7ExampleREADME.md3 matches

@stevekrouseโ€ขUpdated 3 months ago
17```
18โ”œโ”€โ”€ backend/
19โ”‚ โ”œโ”€โ”€ database/
20โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Database schema
21โ”‚ โ”‚ โ””โ”€โ”€ queries.ts # Database queries
22โ”‚ โ””โ”€โ”€ index.ts # Server entry point
23โ”œโ”€โ”€ frontend/

reactRouter7Exampleindex.ts3 matches

@tmcwโ€ขUpdated 3 months ago
9import { readFile, serveFile } from "https://esm.town/v/std/utils@85-main/index.ts";
10import { routes } from "../shared/routes.ts";
11import { initializeDatabase } from "./database/migrations.ts";
12
13// Initialize the database
14await initializeDatabase();
15
16// Create the Hono app

reactRouter7ExampleTopics.action.ts1 match

@tmcwโ€ขUpdated 3 months ago
1import { ActionFunctionArgs, redirect } from "https://esm.sh/react-router@7.5.0?deps=react@18.2.0,react-dom@18.2.0";
2import { createTopic } from "../backend/database/queries.ts";
3
4export async function action({ request }: ActionFunctionArgs) {

reactRouter7ExampleTopicMessage.loader.ts1 match

@tmcwโ€ขUpdated 3 months ago
1import { LoaderFunctionArgs } from "https://esm.sh/react-router@7.5.0?deps=react@18.2.0,react-dom@18.2.0";
2import { getTopicById, getMessageById, getMessagesByTopicId } from "../backend/database/queries.ts";
3
4export async function loader({ params }: LoaderFunctionArgs) {

reactRouter7ExampleTopic.loader.ts1 match

@tmcwโ€ขUpdated 3 months ago
1import { LoaderFunctionArgs } from "https://esm.sh/react-router@7.5.0?deps=react@18.2.0,react-dom@18.2.0";
2import { getTopicById, getMessagesByTopicId } from "../backend/database/queries.ts";
3
4export async function loader({ params }: LoaderFunctionArgs) {

reactRouter7ExampleTopic.action.ts1 match

@tmcwโ€ขUpdated 3 months ago
1import { ActionFunctionArgs } from "https://esm.sh/react-router@7.5.0?deps=react@18.2.0,react-dom@18.2.0";
2import { createMessage } from "../backend/database/queries.ts";
3
4export async function action({ request }: ActionFunctionArgs) {

reactRouter7ExampleSearch.loader.ts1 match

@tmcwโ€ขUpdated 3 months ago
1import { LoaderFunctionArgs } from "https://esm.sh/react-router@7.5.0?deps=react@18.2.0,react-dom@18.2.0";
2import { search } from "../backend/database/queries.ts";
3
4export async function loader({ request }: LoaderFunctionArgs) {

reactRouter7ExampleREADME.md3 matches

@tmcwโ€ขUpdated 3 months ago
17```
18โ”œโ”€โ”€ backend/
19โ”‚ โ”œโ”€โ”€ database/
20โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Database schema
21โ”‚ โ”‚ โ””โ”€โ”€ queries.ts # Database queries
22โ”‚ โ””โ”€โ”€ index.ts # Server entry point
23โ”œโ”€โ”€ frontend/

customer-database-setup2 file matches

@stevenvapiโ€ขUpdated 1 week ago

prDatabase

@pdwโ€ขUpdated 2 weeks ago