Skip to content
This repository has been archived by the owner on Dec 15, 2024. It is now read-only.

chore: scaffold monorepo #4

Merged
merged 7 commits into from
Dec 13, 2024
Merged

chore: scaffold monorepo #4

merged 7 commits into from
Dec 13, 2024

Conversation

sripwoud
Copy link
Collaborator

@sripwoud sripwoud commented Dec 12, 2024

Towards replacing the template rendering engine used for the web interface by a JS/TS application.
In the internal PSE #dogfood, it seems we were all in favor on using a monorepo to manage the freedit rs backend and the to be developed JS client.

I picked a few tools that I am setting up in this PR:

  • bun as JS runtime and node package manager

  • just as tasks runner

  • vite: JS/TS front end build tool

  • tanstack router: client side router
    Right now I am just "dangerously setting" the inner html in one route of client app from what the server gives. But of course we should not keep doing that way, this is just for demo/test purposes atm. Indeed atm the server only serves html documents (the rinja template rendering engine). Eventually we want to have a server that gives us JSON and fetch that client side, and let react build the html docs (see server: implement json api layer #5 and server: remove template rendering logic and deps #6).

    image

Test plan

  • Spin up the server and client: eg with just dev
  • you should not see any errors or warnings
  • go to localhost:5173 . Click on the inn link. You should see the same content as on localhost:3001 (but displayed very ugly)

@sripwoud sripwoud self-assigned this Dec 12, 2024
@sripwoud sripwoud requested review from adria0 and jacque006 December 12, 2024 13:35
adria0
adria0 previously approved these changes Dec 12, 2024
Copy link
Collaborator

@adria0 adria0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not checked JS stuff because I do not have expertice on this, but overall, LGTM.

jacque006
jacque006 previously approved these changes Dec 12, 2024
Copy link
Collaborator

@jacque006 jacque006 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JS setup looks good to me 👍

I assume based on these changes that we will no longer be pulling from freedit upstream. Still might be doable to as custom patches if they make smaller updates. As an example of something we might want: freedit-org#306

README.md Show resolved Hide resolved
README.md Show resolved Hide resolved
config.toml Outdated Show resolved Hide resolved
@sripwoud sripwoud dismissed stale reviews from jacque006 and adria0 via bbf812c December 13, 2024 21:11
@sripwoud sripwoud requested review from adria0 and jacque006 December 13, 2024 21:15
@jacque006 jacque006 merged commit 479e295 into main Dec 13, 2024
@jacque006
Copy link
Collaborator

We'll need to port this to https://github.com/privacy-scaling-explorations/pse-forums , can likely just push main there. Will also include db snapshot logic from #1 & #2

@sripwoud
Copy link
Collaborator Author

@jacque006 yes i wanted to merge it here first as you had started to review it here.
I ll push to main on pse-forums

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants