github valor-software/ngx-bootstrap v21.2.0

7 hours ago

BREAKING CHANGES

  • zoneless: Completed migration to Angular's zoneless change detection. zone.js is no longer required and has been removed from dependencies.
  • zoneless: All components now use ChangeDetectionStrategy.OnPush. Applications must use provideZonelessChangeDetection() in their bootstrap configuration.
  • inputs: All @Input() decorators have been replaced with the input() signal function API. Programmatic access to component inputs now requires signal read syntax (e.g., component.myInput() instead of component.myInput).
  • outputs: All @Output() decorators have been replaced with the output() function API. Output emissions continue to use .emit().
  • services: Removed NgZone dependency from carousel, component-loader, positioning service, and focus-trap. Replaced NgZone.onStable with afterRenderEffect().
  • modules: Removed deprecated forRoot() static method from all 17 module classes (AccordionModule, AlertModule, ButtonsModule, CarouselModule, CollapseModule, BsDatepickerModule, BsDropdownModule, FocusTrapModule, PaginationModule, PopoverModule, ProgressbarModule, RatingModule, SortableModule, TabsModule, TimepickerModule, TooltipModule, TypeaheadModule). These methods were no-ops returning empty providers and were deprecated since v18. Simply use the module directly in imports (e.g., TooltipModule instead of TooltipModule.forRoot()).
  • schematics: ng add schematics now generate module imports without .forRoot().

Features

  • core: Migrated to Angular 21.2.x
  • core: Migrated 230+ @Input() decorators to input() across 35 files
  • core: Migrated 70+ @Output() decorators to output() across 24 files
  • core: All 17 component groups updated for zoneless operation
  • core: Added postinstall warning script for breaking change notifications on npm install

Migration Guide

To upgrade from previous versions:

  1. Update Angular to ^21.2.0
  2. Remove zone.js from your polyfills and dependencies
  3. Add provideZonelessChangeDetection() to your app bootstrap providers
  4. Update any programmatic input access from component.prop to component.prop() (signal read)
  5. See ZONELESS_MIGRATION_PLAN.md for the full migration guide

Don't miss a new ngx-bootstrap release

NewReleases is sending notifications on new releases.