Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NguCarousel Error with Version 7+ #510

Open
rohit-cactus opened this issue Sep 4, 2024 · 1 comment
Open

NguCarousel Error with Version 7+ #510

rohit-cactus opened this issue Sep 4, 2024 · 1 comment

Comments

@rohit-cactus
Copy link

rohit-cactus commented Sep 4, 2024

Issue Report: NguCarousel Error with Version 7+

Description

When using NguCarouselModule in our Angular application, we encounter errors when upgrading from version 6 to version 7 or above. The error manifests as follows:

Error Screenshot:
Screenshot 2024-09-04 at 6 26 22 PM

Current Behavior:

  • The ngu-carousel component is used in the template with [inputs] and [dataSource].
  • Upgrading from NguCarousel version 6 to version 7 or higher results in errors.
  • Adding CUSTOM_ELEMENTS_SCHEMA to the NgModule schemas resolves the issue, but this workaround is not ideal.

Version Information:

  • NguCarouselModule: Version 6 (works as expected)
  • NguCarouselModule: Version 7 and above (causes errors)
  • Angular Version: 15

Steps to Reproduce

  1. Import NguCarouselModule into your Angular module:
    import { NguCarouselModule } from '@ngu/carousel';

  2. Add NguCarouselModule to the imports array of your Angular module.

  3. Use the ngu-carousel component in the template with [inputs] and [dataSource]:
    <ngu-carousel [inputs]="carouselConfig" [dataSource]="items">

  4. Observe the error in the console.

Expected Behavior

The ngu-carousel component should work correctly with [inputs] and [dataSource] without requiring CUSTOM_ELEMENTS_SCHEMA.

Actual Behavior

Errors are thrown, and the ngu-carousel component does not render correctly when using version 7 or above.

Workaround

Adding CUSTOM_ELEMENTS_SCHEMA to the NgModule schemas resolves the issue but is not a desirable solution.

Additional Information

  • NgModule Code:

    @NgModule({
      imports: [
        // other imports
        NguCarouselModule
      ],
      // other module properties
    })
    export class YourModule { }
  • Component Template Code:

    <ngu-carousel [inputs]="carouselConfig" [dataSource]="items">
      <!-- carousel content -->
    </ngu-carousel>

Request

Please investigate the compatibility issue with NguCarousel versions 7 and above and provide guidance or a fix to ensure that the component works without requiring CUSTOM_ELEMENTS_SCHEMA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants
@sheikalthaf @rohit-cactus and others