tinyplex / tinybase

The reactive data store for local‑first apps.
https://tinybase.org
MIT License
3.23k stars 65 forks source link

Fix typo in the docs (basics) #127

Closed arnaudhillen closed 5 months ago

arnaudhillen commented 5 months ago

Summary

Fix a typo in the docs (basics).

How did you test this change?

Did not test.

jamesgpearce commented 5 months ago

Thanks so much for finding and fixing! But just one small thing I suggest. These files are generated from a single piece of markdown, so you should change it there instead:

./site/guides/01_the_basics/4_reading_from_stores.md

The HTML is generated by the build scripts. You can run them too if you want, or I can. Thanks again!

arnaudhillen commented 5 months ago

That makes sense! I looked for a markdown file but didn't immediately find it. I fixed it in the markdown file now.

I tried to build it with npm install && gulp compileDocs but this throws the following error (any idea?)

(py38) arnaudhillen@MacBook-Pro-van-Arnaud site % gulp compileDocs   
[11:17:51] Working directory changed to ~/contribute/tinybase
[11:17:51] Using gulpfile ~/contribute/tinybase/gulpfile.mjs
[11:17:51] Starting 'compileDocs'...
[11:17:52] 'compileDocs' errored after 804 ms
[11:17:52] Error: ENOENT: no such file or directory, scandir './lib'
    at readdirSync (node:fs:1513:3)
    at forEachDirAndFile (file:///Users/arnaudhillen/contribute/tinybase/node_modules/tinydocs/lib/tinydocs.js:26:63)
    at file:///Users/arnaudhillen/contribute/tinybase/tmp/build.js:125:3
    at file:///Users/arnaudhillen/contribute/tinybase/tmp/build.js:144:3
    at ModuleJob.run (node:internal/modules/esm/module_job:217:25)
    at async ModuleLoader.import (node:internal/modules/esm/loader:316:24)
    at async compileDocsAndAssets (file:///Users/arnaudhillen/contribute/tinybase/build/common.mjs:523:19)
    at async compileDocs (file:///Users/arnaudhillen/contribute/tinybase/gulpfile.mjs:144:40)
jamesgpearce commented 5 months ago

I think that's because the docs use TinyBase themselves and need a prod version of the compiled library first. I think you can try:

npm run compileForProdAndDocs
jamesgpearce commented 5 months ago

Want to give that a try? Or I can commandeer this and compile it for you.

arnaudhillen commented 5 months ago

That worked, thanks. (And thanks for the reminder.) The diff now has changes for article.html, index.html and 4_reading_from_stores.md.

jamesgpearce commented 5 months ago

So awesome. Thank you!