|
@@ -1,7 +1,7 @@
|
|
|
# typescript_surrealdb_test
|
|
|
|
|
|
A small test project to try out SurrealDB with Typescript.
|
|
|
-In the DB we will have a User table with a few entries. We will have a frontend in which we use the sdk in order to
|
|
|
+In the DB we will have a 'user' table with a few entries. We will have a frontend in which we use the available official SDK in order to
|
|
|
authenticate and read the user entries.
|
|
|
|
|
|
## Setup
|
|
@@ -10,12 +10,12 @@ With SurrealDB installed Let's start out with a on-disk test database with a sin
|
|
|
surreal start --user root --pass root rocksdb:/home/david/typescript_surrealdb_test/ts_test.db
|
|
|
```
|
|
|
|
|
|
-In our TypeScript project let's install the surrealdb sdk.
|
|
|
+In our TypeScript project let's install the SurrealDB SDK.
|
|
|
```bash
|
|
|
npm i surrealdb
|
|
|
```
|
|
|
|
|
|
-Using the TypeScript sdk we create a schemaless table 'user' with two fields: first_name and last_name.
|
|
|
+Using the TypeScript SDK we create a schemaless table 'user' with two fields: 'first_name' and 'last_name'.
|
|
|
Also we create two test entries for that table. We then try to fetch and display these entries in our frontend.
|
|
|
|
|
|
Running our vite development server
|