Skip to content

bug: ion-datetime triggers ionChange on load #20873

Closed

Description

@jeydsamy

Bug Report

Ionic version:

[x] 5.x

Current behavior:

ion-datetime is triggering ionChange on page load

Expected behavior:

ion-datetime should trigger ionChange only after user changes the date/time

Steps to reproduce:

A sample application via GitHub
https://github.com/jeydsamy/ionic-datetime-sample

  1. Clone project from git, npm install and run with ionic serve
  2. Navigate between tabs, console will print "Date Changed!" even when it is not changed.

Activity

  1. jeydsamy commented on Mar 31, 2020

    @jeydsamy
    Author

    @liamdebeasi Can I please get an answer on this?

  2. liamdebeasi commented on Mar 31, 2020

    @liamdebeasi
    Contributor

    Thanks for the issue. I was able to reproduce this behavior. Seems similar to #19204.

  3. jeya-duraisamy commented on Mar 31, 2020

    @jeya-duraisamy

    Yes, it is similar to #19204. Thanks for looking into it @liamdebeasi

  4. jeya-duraisamy commented on Apr 3, 2020

    @jeya-duraisamy

    @liamdebeasi Sorry if it is too soon, any idea when this might be fixed?

  5. sean-perkins commented on Jul 6, 2022

    @sean-perkins
    Contributor

    Hello everyone, we have an open RFC that proposes a change to ionChange that would help alleviate this issue.

    Please take a moment to review and let us know your thoughts: #25532

  6. liamdebeasi commented on Oct 6, 2022

    @liamdebeasi
    Contributor

    Hi everyone,

    I have a dev build that should resolve this issue: 6.2.10-dev.11665068791.18581fab

    Please note that this is a build of Ionic 7 and is subject to the Ionic 7 Breaking Changes.

  7. added a commit that references this issue on Oct 11, 2022
    cc2af20
  8. liamdebeasi commented on Oct 11, 2022

    @liamdebeasi
    Contributor

    Thanks for the issue. This has been resolved via #26083, and a fix will be available in an upcoming release of Ionic Framework. Please note that this fix requires a breaking change, so it is being targeted for the Ionic 7.0 release. Please feel free to continue testing the dev build, and let me know if you have any questions.

  9. ionitron-bot commented on Nov 10, 2022

    @ionitron-bot

    Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

  10. locked and limited conversation to collaborators on Nov 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions