aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2023-01-07 01:42:48 +0530
committerAkshay Nair <phenax5@gmail.com>2023-01-07 01:42:48 +0530
commitc79c5bf7a44c59cd1e484a538e2dddf264012f57 (patch)
tree43d1518824b55901f69ef800bf8db987d8f07d95
parent05c605d1363c3bce492f4360d774154f8b04c403 (diff)
downloadts-types-lang-c79c5bf7a44c59cd1e484a538e2dddf264012f57.tar.gz
ts-types-lang-c79c5bf7a44c59cd1e484a538e2dddf264012f57.zip
docs: readme
-rw-r--r--README.md7
-rw-r--r--examples/file.ts2
2 files changed, 3 insertions, 6 deletions
diff --git a/README.md b/README.md
index 1f82e4f..c52e304 100644
--- a/README.md
+++ b/README.md
@@ -1,5 +1,5 @@
# TS Types lang [WIP]
-A runtime for ts types that turns it into a general purpose, purely functional programming language!
+A runtime for typescript's **type system** that turns it into a **general purpose**, **purely functional** programming language!
Take a look at the [./examples](./examples) directory for examples on how to write a program in typescript types
@@ -11,10 +11,7 @@ import { PutString, PutStringLn, Bind, Kind1, ReadLine, Do } from 'ts-types-lang
// :: string -> Effect ()
interface GreetK extends Kind1<string> {
- return: Do<[
- PutString<"Hello, ">,
- PutStringLn<this['input']>
- ]>,
+ return: PutString<`Hello, ${this['input']}`>,
}
// main :: [Effect ()] | Effect ()
diff --git a/examples/file.ts b/examples/file.ts
index b0942de..279a51b 100644
--- a/examples/file.ts
+++ b/examples/file.ts
@@ -1,4 +1,4 @@
-import { Bind, Kind1, ReadFile, PutStringLn } from '../stdlib'
+import { Bind, Kind1, ReadFile, WriteFile, PutStringLn } from '../stdlib'
interface PrintK extends Kind1<string> {
return: PutStringLn<this['input']>