rodrigo-brito / gocity

:bar_chart: Code City metaphor for visualizing Go source code in 3D
https://go-city.github.io
MIT License
1.8k stars 139 forks source link

cleanup and refactor #77

Open stevegt opened 2 years ago

stevegt commented 2 years ago

While working on #66 and #76 I'm finding that working on this project is pretty unwieldy due to half of the code being in a different branch -- it really needs to be refactored into one branch. As things stand right now, it's certainly chasing off contributors -- taking a look at the forks makes me think there are a bunch of folks who have done a lot of work but who haven't been able to merge what they've done back into the master repo -- there are some duplicate efforts going on out there as well. I'm finding that the split-branch situation turns what should be a fun set of enhancements into a real chore.

I'm adding a stanza to the Makefile in my own fork to manage the two branches, copying assets over as mentioned in the comments in #66, but it's a horrible kludge.

@rodrigo-brito, you mention in #66 that the split branches was due to getting github to recognize the project as Go rather than javascript, but I'm not following that reasoning -- why do we care what language github shows for the project? Mixed-language projects are common -- any large project is going to be mixed-language. There must be something I'm missing.

Other refactoring that would help:

I'd be happy to submit PRs to clean up any of this, but the split-branch situation makes that extra hard and is likely a prereq.

rodrigo-brito commented 2 years ago

A good cleanup: remove React. The project core is the Go project. Frontend branch only helps with the view. Indeed, we can join both branches, but first, we need to remove React and use vanilla JS to helps with Go integration.

To transpile JS code, we can use ESBuild (https://esbuild.github.io/api/), which works with native Go code and works fine with embed files.

emmanuelay commented 2 years ago

Any progress on this? Would be great to have a monorepo with backend/frontend…