Build better business applications, faster. No more juggling REST endpoints or deciphering GraphQL queries. Hilla seamlessly connects Spring Boot and React to accelerate application development.
Calling a signal endpoint requires providing initial client-side value. Coming up with initial value for complex types is inherently complex. A full value could end up as a lengthy literal:
const person = new PersonEndpoint.personSignal({defaultValue: {name: '', dob: '1970-01-01'}});
This complexity could be mitigated with some help from a generated model:
const person = new PersonEndpoint.personSignal({defaultValue: PersonModel.createEmptyValue()});
However, we could reduce the complexity even further by using the model data on the Hilla end, so that using the signals don't require default value:
const person = new PersonEndpoint.personSignal(); // initialized using the model
Calling a signal endpoint requires providing initial client-side value. Coming up with initial value for complex types is inherently complex. A full value could end up as a lengthy literal:
This complexity could be mitigated with some help from a generated model:
However, we could reduce the complexity even further by using the model data on the Hilla end, so that using the signals don't require default value: