Skip to content

bug: [angular] ModalController is not compatible with Angular signal inputs #30784

Closed as duplicate

Description

@hakimio

Prerequisites

Ionic Framework Version

v8.x

Current Behavior

ModalController is not compatible with Angular signal inputs

Expected Behavior

ModalController is compatible with Angular signal inputs

Steps to Reproduce

  1. Create Angular component with signal inputs
  2. Try to set its inputs using ModalController.create().

Code Reproduction URL

Ionic Info

@ionic/angular: 8.7.9

Additional Information

No response

Activity

  1. ionitron-bot commented on Nov 18, 2025

    @ionitron-bot

    Thanks for the issue! This issue has been labeled as needs reproduction. This label is added to issues that need a code reproduction.

    Please reproduce this issue in an Ionic starter application and provide a way for us to access it (GitHub repo, StackBlitz, etc). Without a reliable code reproduction, it is unlikely we will be able to resolve the issue, leading to it being closed.

    If you have already provided a code snippet and are seeing this message, it is likely that the code snippet was not enough for our team to reproduce the issue.

    For a guide on how to create a good reproduction, see our Contributing Guide.

  2. hakimio commented on Nov 19, 2025

    @hakimio
    Author

    Ok, you have to manually enable useSetInputAPI in Ionic config for this to work.
    @ShaneK I can't find this config in the docs and why can't Ionic just automatically check if the setInput() method is defined?

    EDIT: this is duplicate of #28876 . Anyway, useSetInputAPI should be enabled by default at this point since it's available since Angular v14 and @ionic/angular supports only Angular v16+.

  3. ShaneK commented on Nov 19, 2025

    @ShaneK
    Member

    Excellent find, @hakimio! That's a solid point, we should probably do that. I wasn't sure what the root of this issue was, which is why I needed the reproduction, but I'm glad you found it. Thank you!

  4. hakimio commented on Nov 19, 2025

    @hakimio
    Author

    @ShaneK so, are you planning to enable this by default since all supported Angular versions provide ComponentRef.setInput() API?

  5. ShaneK commented on Nov 19, 2025

    @ShaneK
    Member

    Yeah, I've created a card around validating our defaults for Angular apps with this specific point involved. It doesn't have priority right now and we're all pretty busy with other tasks, but at least we know about it now. If you'd like to PR the change, it would be pretty easy here:
    https://github.com/ionic-team/starters

    Specifically, these two places I believe:
    https://github.com/ionic-team/starters/blob/main/angular-standalone/base
    https://github.com/ionic-team/starters/blob/main/angular/base

  6. hakimio commented on Nov 19, 2025

    @hakimio
    Author

    The right thing to do would be to remove the config entirely and do the right thing by default instead of changing the starters to have this config enabled.

  7. ShaneK commented on Nov 19, 2025

    @ShaneK
    Member

    Feel free to open a PR for that instead then. That's probably the conclusion we'll come to when we review it, but reviewing the defaults is still something that should be done.

  8. hakimio commented on Nov 21, 2025

    @hakimio
    Author

    @ShaneK I have opened #30803 PR.

  9. ionitron-bot commented on Dec 21, 2025

    @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 Dec 21, 2025
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