pez-globo / pufferfish-software

All software for the Pufferfish ventilator.
Apache License 2.0
0 stars 1 forks source link

Frontend shouldn't initialize values #312

Closed ethanjli closed 3 years ago

ethanjli commented 3 years ago

Right now, when the frontend starts it initializes all values with defaults. This overwrites any settings loaded from the backend, which is very bad. We should have the frontend wait for the backend to supply all parameters, and maybe also some other relevant settings.

This could be achieved by allowing setting the Typescript types for some messages to be optional, so that we just wait for an incoming message to initialize them. We would also want to avoid sending null messages to the backend.