Search
realMiningApps
@Sagar445
@jsxImportSource https://esm.sh/react@18.2.0
HTTP
// Cryptocurrency Mining Simulator
function CryptoMiningApp() {
const [miners, setMiners] = useState([
</div>
function App() {
return <CryptoMiningApp />;
function client() {
createRoot(document.getElementById("root")).render(<App />);
if (typeof document !== "undefined") { client(); }
export default async function server(request: Request) {
return new Response(`
generateImageSummary
@jackd
An interactive, runnable TypeScript val by jackd
Script
import { OpenAI } from "https://esm.town/v/std/openai";
import { fileToDataURL } from "https://esm.town/v/stevekrouse/fileToDataURL";
export async function generateImageSummary(image: File): Promise<string[]> {
const openai = new OpenAI();
const dataURL = await fileToDataURL(image);
const response = await openai.chat.completions.create({
model: "gpt-4-vision-preview",
val_XVD3rKaITU
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function val_XVD3rKaITU(req) {
try {
// Execute the code directly and capture its result
![nariman avatar](https://images.clerk.dev/oauth_github/img_2QtkYucDVwJCwZjGQ2rebIXvUuG.jpeg)
myApi
@nariman
An interactive, runnable TypeScript val by nariman
Script
export function myApi(name) {
return "hi " + name;
![benfwalla avatar](https://images.clerk.dev/oauth_github/img_2Rc7brEOq7beI1o1jFeLA0DRcXk.png)
myApi
@benfwalla
An interactive, runnable TypeScript val by benfwalla
Script
export function myApi(name) {
var sentence = "hi " + name;
console.email(sentence);
![nerdswhosell avatar](https://images.clerk.dev/oauth_github/img_2Sl3w3ko9UvHLtXi6vOp0b1bCMJ.jpeg)
myApi
@nerdswhosell
An interactive, runnable TypeScript val by nerdswhosell
Script
export function myApi(name) {
return "hi " + name;
![pomdtr avatar](https://images.clerk.dev/oauth_github/img_2RCoAITJZH1QencEgtVjh4Qirj4.jpeg)
val_town_openapi
@pomdtr
An interactive, runnable TypeScript val by pomdtr
HTTP
import { blob } from "https://esm.town/v/std/blob?v=12";
export default async function() {
const resp = await blob.get("openapi.yaml")
return new Response(resp.body, {
litepickbet
@cyrilos
cookies manager class
HTTP
/* events */
/* run function on win */
onWin(func) {
this.winHandlers.push(func);
/* run function on loss */
onLoss(func) {
this.lossHandlers.push(func);
/* run function on every bet */
onBet(func) {
/* main app */
async function loop() {
var url = "https://cyrilos-litepickbet.web.val.run";
/* bet session */
async function playDice() {
const PLATFORM = "litepick.io";
valle_tmp_016298797667905655232930394407136
@janpaul123
@jsxImportSource https://esm.sh/react
HTTP
import OpenAI from "npm:openai";
unless strictly necessary, for example use APIs that don't require a key, prefer internal function
functions where possible. Unless specified, don't add error handling,
The val should create a "export default async function main() {" which
is the main function that gets executed, without any arguments. Don't return a Response object,
// The val should create a "export default async function main() {" which
// is the main function that gets executed, without any arguments. Don't return a Response object,
function write(text) {
function updateValName(valName) {
function saveVal() {
valle_tmp_62253074104033147819150473701293
@janpaul123
@jsxImportSource https://esm.sh/react
HTTP
import OpenAI from "npm:openai";
unless strictly necessary, for example use APIs that don't require a key, prefer internal function
functions where possible. Unless specified, don't add error handling,
The val should create a "export default async function main" which is the main function that gets
// The val should create a "export default async function main() {" which
// is the main function that gets executed, without any arguments. Don't return a Response object,
function write(text) {
const callback = function (mutationsList, observer) {
function updateValName(valName) {
function saveVal() {
myApi
@goki
An interactive, runnable TypeScript val by goki
Script
export function myApi(name) {
return "hi " + name;
dm_callback_example
@karanganesan
Docs: https://docs.lumalabs.ai/docs/api#how-to-get-a-callback-when-generation-has-an-update you can now pass callback_url in the body of api / create function on python/js sdks.
available on version 1.1.0 To upgrade python sdk pip install lumaai --upgrade To upgrade js sdk npm install lumaai@latest or pnpm install lumaai@latest or yarn add lumaai@latest
HTTP
Docs: https://docs.lumalabs.ai/docs/api#how-to-get-a-callback-when-generation-has-an-update
you can now pass callback_url in the body of api / create function on python/js sdks.
available on version 1.1.0
export default async function(req: Request): Promise<Response> {
const timeNow = new Date();
// give me time in ist time detailed use js
web_kH7d5ah6xz
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function web_kH7d5ah6xz(req) {
return new Response(`<!DOCTYPE html>
<html>