Skip to content

onChange not working in browser #9

@dracoblackie

Description

@dracoblackie

I have tested some code in android, and it worked fine. Then when run in chrome it seems like we dont hit onChange.

Neither with a static value
<WheelPicker
selectedIndex={defaultIndex}
options={someOptionsArray}
onChange={(index) => this.setState({someStateValue: 2})}
/>
or if we set someStateValue to someOptionsArray[index]

In chrome devtools, i have set a debugpoint at onChange. When i run it on an android emulator we hit it in the debugger, but when run on a webserver, we dont hit the onChange.
Additionally i have tried with a simple console.log("hello world") instead =>
<WheelPicker
selectedIndex={defaultIndex}
options={someOptionsArray}
onChange={(index) => {
console.log("Hello World")
}
}
/>
We do not seem to get the message in the console of the browser.

In both tests i have used mouse and keyboard.

I will isolate the code into a modal module to see if this fixes things, but thought this would be helpfull.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions