Comments (1)
The problem is that the onInput
modifier is not specific to the element to which it is applied. (Unfortunately, this lives in the generated part of the code so I cannot provide a link here, but you can check locally the GlobalEventProps.scala
file under src_managed
.) Incidentally, there is a nice solution to this problem in the ff4s-shoelace
project (idea stolen from https://github.com/sherpal/LaminarSAPUI5Bindings). See for example https://github.com/buntec/ff4s-shoelace/blob/7ce368d6f975c0f6663a9db3a2c36ac3e2b2d153/ff4s-shoelace/src/main/scala/ff4s/shoelace/Textarea.scala#L35. Here the onInput
modifier is made more precise. In particular, the target
attribute has the exact type of the element. The downside to this approach is that you have to prefix things like onInput
with the element type: sl.TextArea(sl.TextArea.onInput := ...)
etc. Achieving a similar thing for non-web-components would require changes in the domtypes project, I think, where all the codegen heavy lifting resides.
from ff4s.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ff4s.