-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
bugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is needed
Description
I'd like to have something like a signal that reads the current date:
dateTimeWidg :: Widget HTML DateTime
dateTimeWidg = liftEffect nowDateTime
dateTimeSig :: Signal HTML DateTime
dateTimeSig = sig initDate
where
sig dt = step dt do
newDt <- dateTimeWidg
pure $ sig newDt
The widget seems fine, however, the signal creates an infinite (eagerly evaluated) loop, since dateTimWidg
returns immediately.
Ideally, there would be a way to have dateTimeSig
only queried when other signals at the same level fire. The particular goal here is that I have user's inputting data to records, but this particular field of the record should be automatically timestamped by the app.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is needed