logseq/tldraw
Adam Hupp c7e0d86e8b Fix `yarn install` on Windows
`yarn install` currently fails due to two issues:

 a) several build scripts use "cd some_dir && yarn ...", which is not
 valid in cmd.exe.  Replace with "yarn --cwd some_dir .."
 b) zx is somehow defaulting to bash, which finds WSL and runs the
 script in the WSL instance.  Supposedly this was fixed in
 https://github.com/google/zx/pull/458, not sure why it's not working
 even if I upgrade zx.
2023-05-04 13:51:17 +08:00
..
apps/tldraw-logseq Fix `yarn install` on Windows 2023-05-04 13:51:17 +08:00
assets move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
cljs-demo fix: demo elements 2022-11-01 13:43:13 +02:00
demo feat: grouping & ungrouping shapes (#7713) 2022-12-15 22:58:18 +08:00
packages style: run prettier 2023-05-03 15:30:05 -04:00
.editorconfig Add editor config 2022-08-26 12:59:27 +03:00
.eslintignore move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
.eslintrc fix: scroll offset issue 2022-05-30 15:22:35 +08:00
.gitattributes move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
.gitignore move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
.npmignore move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
.prettierrc run prettier 2022-07-03 21:38:09 +08:00
LICENSE.md move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
README.md fix: readme typos (#7451) 2022-11-25 08:50:27 +08:00
package.json Fix `yarn install` on Windows 2023-05-04 13:51:17 +08:00
tsconfig.base.json fix: merge issue 2022-08-26 21:56:02 +08:00
tsconfig.json move tldraw/next inside of logseq 2022-05-16 19:55:07 +08:00
yarn.lock Fix `yarn install` on Windows 2023-05-04 13:51:17 +08:00

README.md

Developer Notes

Background

This folder contains the JS codes for a custom build of Tldraw to fit the needs of Logseq, which originates from an abandoned next branch from the author of Tldraw.

Development

Prerequisites

Modern JS eco tools like Node.js and yarn.

Run in dev mode

  • install dependencies with yarn
  • run dev mode with yarn dev, which will start a Vite server at http://127.0.0.1:3031/

Note, the dev mode is a standalone web app running a demo Tldraw app in tldraw/demo/src/App.jsx. The Logseq component renderers and handlers are all mocked to make sure Tldraw only functions can be isolatedly developed.

Other useful commands

  • fixing styles: yarn fix:style
  • build: yarn build

How it works

Data flow between Tldraw & Logseq

The data flow between Tldraw & Logseq can be found here: https://whimsical.com/9sdt5j7MabK6DVrxgTZw25