Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions f/examples/ebullient_script2.script.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"version": "3",
"remote": {}
}
36 changes: 36 additions & 0 deletions f/examples/ebullient_script2.script.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
summary: ''
description: ''
lock: '!inline f/examples/ebullient_script2.script.lock'
concurrency_time_window_s: 0
kind: script
schema:
$schema: 'https://json-schema.org/draft/2020-12/schema'
type: object
properties:
a:
type: number
description: ''
default: null
b:
type: string
description: ''
default: null
enum:
- my
- enum
d:
type: string
description: ''
default: inferred type string from default arg
e:
type: object
description: ''
default:
nested: object
properties:
nested:
type: string
required:
- a
- b
tag: ''
19 changes: 19 additions & 0 deletions f/examples/ebullient_script2.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// Ctrl/CMD+. to cache dependencies on imports hover.

// Deno uses "npm:" prefix to import from npm (https://deno.land/[email protected]/node/npm_specifiers)
// import * as wmill from "npm:[email protected]"

// fill the type, or use the +Resource type to get a type-safe reference to a resource
// type Postgresql = object

export async function main(
a: number,
b: "my" | "enum",
//c: Postgresql,
d = "inferred type string from default arg",
e = { nested: "object" },
//e: wmill.Base64
) {
// let x = await wmill.getVariable('u/user/foo')
return { foo: a };
}