From af35cde2d8cce78edcc90b02e8e3655897366a21 Mon Sep 17 00:00:00 2001 From: Eduard Urbach Date: Thu, 6 Jul 2023 14:48:29 +0200 Subject: [PATCH] Improved documentation --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e388595..88889fb 100644 --- a/README.md +++ b/README.md @@ -4,13 +4,15 @@ In-memory key value store that saves your data to plain old JSON files. If you like, you can operate on your entire data with classic UNIX tools. +Suitable for small to medium data volume. + ## Installation ```shell go get git.akyoto.dev/go/ocean ``` -## Examples +## Example ```go // User data @@ -23,6 +25,9 @@ users := ocean.New[User]("User") // Store key and value in memory and write ~/.ocean/User/1.json users.Set("1", &User{Name: "User 1"}) + +// Read value from memory +user, err := users.Get("1") ``` In a real project you would usually prefix your collections with a project or company name: