server-reason-react
server-reason-react copied to clipboard
Could we compose switch%platform with other variables?
Could we have a composable switch%platform
with other variables?
Instead of having:
switch%platform (Runtime.platform) {
| Client =>
switch (foo) {
| (true) => // ...
| (false) => // ...
}
| Server => // ...
}
switch%platform (Runtime.platform, foo) {
| (Client, _) => // ...
| (Server, false) => // ...
// ...
}
Does it make sense?