This PR tries to close #42 (Replace React with something simple). I have migrated the stack to just use Typescript, HTML and CSS. NO FRAMEWORKS.
Basic setup
Fastboot functionality is refactored into a class that extends EventTarget. EventTarget basically allows you to attach event listeners. Here is an example:
const fb = new FastbootManager()
fb.on("progress", (newState) => updateUI(newState))
Almost all of the UI is now part of index.html and those parts of frontend that have some kind of interactivity (ex: progress indicator, device connection status, buttons, etc) are in src/main.ts file. Here is an example of how progress indicator is handled:
This setup should simplify the stack and hopefully is exactly what @adeebshihadeh was expecting.
Pending steps
I still have to migrate a couple of tests to this new setup. However, the project runs locally. I will need help from someone who owns an actual device to try and flash the device just to make sure everything is working fine.
@adeebshihadeh let me know if anything else is required to Lock the bounty. Thanks! Was fun working on this :)
This PR tries to close #42 (Replace React with something simple). I have migrated the stack to just use Typescript, HTML and CSS. NO FRAMEWORKS.
Basic setup
Fastboot functionality is refactored into a class that extends
EventTarget
.EventTarget
basically allows you to attach event listeners. Here is an example:Almost all of the UI is now part of
index.html
and those parts of frontend that have some kind of interactivity (ex: progress indicator, device connection status, buttons, etc) are insrc/main.ts
file. Here is an example of how progress indicator is handled:This setup should simplify the stack and hopefully is exactly what @adeebshihadeh was expecting.
Pending steps
I still have to migrate a couple of tests to this new setup. However, the project runs locally. I will need help from someone who owns an actual device to try and flash the device just to make sure everything is working fine.
@adeebshihadeh let me know if anything else is required to Lock the bounty. Thanks! Was fun working on this :)