bigskysoftware / bigskysoftware/_hyperscript
On with multiple clauses via 'or' does not allow 'from' clause.
- Lingua principale
- JavaScript
- Stelle
- 3.8k
- Fork
- 172
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Minimal repo case showing that separate `on` handlers works, but that two `on` handlers each with a `from` clause causes a "Expected commandList" error.
```html
behavior SeparateWorks
on first from #events
toggle [@hidden] on me
end
on second from #events
toggle [@hidden] on me
end
end
behavior FirstDoesntWork
-- No syntax error, but first function doesn't toggle
on first or second from #events
toggle [@hidden] on me
end
end
behavior SecondDoesntWork
-- No syntax error, but second button doesn't toggle
on first from #events or second
toggle [@hidden] on me
end
end
-- in a separate script so syntax error doesn't break other cases....
behavior Broken
on first from #events or second from #events
toggle [@hidden] on me
end
end
First
Second
- Separate Works - Initial
- Separate Works - Toggled
- Doesn't Work First - Initial
- Doesn't Work First - Toggled
- Doesn't Work Second - Initial
- Doesn't Work Second - Toggled
- Broken - Initial
- Broken - Toggled
```
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Inizia con la riproduzione HTML minima e segui il parsing degli handler `on` di hyperscript contenenti `from` e `or`. Confronta gli handler separati funzionanti con le forme combinate che falliscono. Il lavoro è completato quando entrambi gli handler vengono analizzati senza l’errore `Expected commandList` e rispondono ai rispettivi eventi.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- javascript
- Ambito
- compilers
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 45/100