Replies: 4 comments 1 reply
-
I think splitting the frontend and backend is definitely a good idea, and I never liked anything about the selected stack anyway. It does sound like quite a lot of work though so it's a bit shame the development started out like this. The biggest issue for me is the site ui and ux which isn't very good now especially with mobile devices. I would've hoped when people write new features and layouts it was a requirement to test it properly with smaller windows so that it works, and some design rules and style guides should be obeyed. But I guess that's a bit late now if there's a rush to get features done in the first place. One other thing to mention is writing 3rd party apps using the rest api. The api works and is getting more complete as parts of the site is being refactored so that's good, but it's not possible to perform user auth requiring actions because of cross origin cookie policy, so that should be looked at. In general when writing the rest api it should be considered that various different apps could be using it. |
Beta Was this translation helpful? Give feedback.
-
I've started on the frontend split here https://github.com/elmadev/elmaonline-web/ let me know if you have any thoughts on the structure etc. |
Beta Was this translation helpful? Give feedback.
-
Didn't read this thread until now but the decision to do this was a huge plus in my opinion. Build time and ease of use on client is fantastic compared to what it used to be (and overall). |
Beta Was this translation helpful? Give feedback.
-
So to follow up on this, I've now split out the discord code to https://github.com/elmadev/elmaonline-discord and redone the nodejs/express set up for the backend, which still had a lot of leftover from the original starter kit when it also included frontend. Main things to note is it's using nodejs esm mode, which means you need node 16.10+, cannot use require() in our code (use import instead) and named imports from some old libraries may not work. Also uses yarn 3.x, you need to run |
Beta Was this translation helpful? Give feedback.
-
Had a talk with 8ball a while ago and he suggested some improvements, so I wanted to discuss these before we settle on anything.
The project is starting to grow to a bigger size and with many things in one repo (frontend, backend, bot) it might be a bit combersome to navigate the codebase. So we can consider splitting it into 2 or 3 repos. Splitting backend and frontend is pretty common for bigger projects and will allows us to do other things. Such as migrating to create-react-app for the frontend which is more commonly used nowadays, getting rid of the isomorphic (server/client rendered) approach which has caused a lot of issues. Would also help out with building which is pretty slow now and is causing some memory issues. The negative side would be that it might be more complicated to run locally and release. For releasing hopefully we can the github actions working so it's automatic so that's not an issue.
Currently we have two milestones, feature parity with old site and removing apollo/graphql. So we'd finish these first and then start to look at the above. Beyond that I'd like to look at componentizing things a bit better, especially ui which has a lot of one time use things currently. Also improving ui for mobile.
Nothings set in stone, so I'd like everyone opinion on this, and are there others things that work well or doesn't work well with current codebase?
Beta Was this translation helpful? Give feedback.
All reactions