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=database&page=282&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 2828 results for "database"(267ms)

dateme_sqlitemain.tsx1 match

@stevekrouse•Updated 1 year ago
34}
35
36export async function setupDatabase() {
37 await createTable();
38 const docs = await fetchJSON(thisWebURL());

listSqliteTablesREADME.md1 match

@nbbaier•Updated 1 year ago
1# listSqliteTables
2
3Returns a flat array of the names of all tables in your Val Town SQLite database.
4
5```ts

sqliteDumpREADME.md1 match

@nbbaier•Updated 1 year ago
1# SQLite Dump Util
2
3A utility function that generates SQL statements to dump the data and schema of tables in a SQLite database.
4
5## Usage

dateme_sqliteREADME.md2 matches

@stevekrouse•Updated 1 year ago
2
3```ts
4import { setupDatabase } from "https://esm.town/v/stevekrouse/dateme_sqlite"
5
6await setupDatabase()
7```
8

datascriptExampleREADME.md1 match

@tmcw•Updated 1 year ago
1# datascript example
2
3An example using tonsky’s [datascript](https://github.com/tonsky/datascript) module, which implements a datalog-style database in JavaScript. The module itself is really written in ClojureScript, but they've helpfully produced an npm-compatible module for us to use. [Datalog](https://en.wikipedia.org/wiki/Datalog) languages are fascinating, and have some real-world use in Roam Research and Logseq.

getDuckDBREADME.md2 matches

@tmcw•Updated 1 year ago
1# Get a DuckDB database
2
3This method sets up a [duckdb-wasm](https://github.com/duckdb/duckdb-wasm) database that you can then use to store and retrieve data.

nanoidExampleREADME.md1 match

@tmcw•Updated 1 year ago
5- They're shorter, with a more customizable alphabet.
6- They use more different characters by default.
7- Unlike UUIDs, there aren't custom types for nanoids in databases
8- Nanoids never contain information. UUIDs sometimes do: some UUIDs contain timestamps and MAC addresses.
9