diff options
| author | muddlebee <anweshknayak@gmail.com> | 2024-07-10 06:43:34 +0530 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-09 21:13:34 -0400 |
| commit | ff5163af05d95409cbb3d1a13f49a43fefd4849a (patch) | |
| tree | 1b441f411224a0f45177beb77ba7822505cc8166 /cli/tools/init/templates | |
| parent | 9776a13e33bc371a67f0d44925e2bf04dca159f1 (diff) | |
feat(cli): `deno init --lib` (#22499)
Closes #22287
Co-authored-by: Asher Gomez <ashersaupingomez@gmail.com>
Co-authored-by: David Sherret <dsherret@gmail.com>
Diffstat (limited to 'cli/tools/init/templates')
| -rw-r--r-- | cli/tools/init/templates/deno.json | 5 | ||||
| -rw-r--r-- | cli/tools/init/templates/main.ts | 8 | ||||
| -rw-r--r-- | cli/tools/init/templates/main_test.ts | 6 |
3 files changed, 0 insertions, 19 deletions
diff --git a/cli/tools/init/templates/deno.json b/cli/tools/init/templates/deno.json deleted file mode 100644 index 3c5130f1d..000000000 --- a/cli/tools/init/templates/deno.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "tasks": { - "dev": "deno run --watch main.ts" - } -} diff --git a/cli/tools/init/templates/main.ts b/cli/tools/init/templates/main.ts deleted file mode 100644 index be043e97c..000000000 --- a/cli/tools/init/templates/main.ts +++ /dev/null @@ -1,8 +0,0 @@ -export function add(a: number, b: number): number { - return a + b; -} - -// Learn more at https://deno.land/manual/examples/module_metadata#concepts -if (import.meta.main) { - console.log("Add 2 + 3 =", add(2, 3)); -} diff --git a/cli/tools/init/templates/main_test.ts b/cli/tools/init/templates/main_test.ts deleted file mode 100644 index 26af2582b..000000000 --- a/cli/tools/init/templates/main_test.ts +++ /dev/null @@ -1,6 +0,0 @@ -import { assertEquals } from "jsr:@std/assert"; -import { add } from "./main.ts"; - -Deno.test(function addTest() { - assertEquals(add(2, 3), 5); -}); |
