diff --git a/f/examples/ebullient_script2.script.lock b/f/examples/ebullient_script2.script.lock new file mode 100644 index 0000000..37f10ce --- /dev/null +++ b/f/examples/ebullient_script2.script.lock @@ -0,0 +1,4 @@ +{ + "version": "3", + "remote": {} +} diff --git a/f/examples/ebullient_script2.script.yaml b/f/examples/ebullient_script2.script.yaml new file mode 100644 index 0000000..d286ad6 --- /dev/null +++ b/f/examples/ebullient_script2.script.yaml @@ -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: '' diff --git a/f/examples/ebullient_script2.ts b/f/examples/ebullient_script2.ts new file mode 100644 index 0000000..f36fc1c --- /dev/null +++ b/f/examples/ebullient_script2.ts @@ -0,0 +1,19 @@ +// Ctrl/CMD+. to cache dependencies on imports hover. + +// Deno uses "npm:" prefix to import from npm (https://deno.land/manual@v1.36.3/node/npm_specifiers) +// import * as wmill from "npm:windmill-client@1.256.0" + +// 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 }; +}