question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

onChangeRaw event not working

See original GitHub issue

Expected behavior

should be able to use onChangeRaw to get event object

Actual behavior

onChangeRaw doesn’t trigger at all (tried passing IIFE, it triggers but it will not return event object)

Steps to reproduce

use this example: https://reactdatepicker.com/#example-44 handleChangeRaw(value) { if(value === "tomorrow") { const tomorrow = moment().add(1, "day") this.handleChange(tomorrow) } } <DatePicker selected={this.state.startDate} onChange={this.handleChange} placeholderText="Enter tomorrow" onChangeRaw={(event) => this.handleChangeRaw(event.target.value)} />

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:17
  • Comments:13

github_iconTop GitHub Comments

9reactions
goldfarbdevcommented, Mar 17, 2019

I can’t get this to work even with new version 2.2.0

3reactions
doublejoshcommented, Nov 20, 2019

This event is very necessary, because there’s no other way to get an id attribute to use a generic handler function to update the state and backend data storage.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Problem with date (react-datepicker) when i paste new date in ...
Above screen - initial state date. But when i copy new date i try paste into input date. enter image description here. I...
Read more >
react-datepicker - npm
A simple and reusable datepicker component for React. Latest version: 4.8.0, last published: 7 months ago. Start using react-datepicker in ...
Read more >
OnChange event not firing in React MDBDatePicker
Hi,. Unfortunately, there is only one way to get event object: use onInputChange method in addition to keyboard property and change value of...
Read more >
React Datepicker crafted by HackerOne
A simple and reusable datepicker component for React. Installation. The package can be installed via NPM: npm install react-datepicker --save. Or by using...
Read more >
Hacker0x01 - Bountysource
onChangeRaw event not working $ 0. Created 4 years ago in Hacker0x01/react-datepicker with 13 comments. Expected behavior. should be able to use ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found