-
Notifications
You must be signed in to change notification settings - Fork 480
Open
Copy link
Labels
Description
Upgrade PrimeNG from 17.18.11 to 20
Overview
This issue tracks the migration from PrimeNG 17.18.11 to PrimeNG 20, which includes significant breaking changes that require careful migration planning and execution.
Current State
- Current Version: PrimeNG 17.18.11
- Target Version: PrimeNG 20
- Angular Version: 20.3.9 (compatible)
- Related Dependencies:
primeicons: 7.0.0 (may need update)primeflex: 3.3.1 (verify compatibility)
Major Breaking Changes
Component Migrations Required
The following components have been deprecated/renamed and need migration:
-
Calendar → DatePicker
- All
CalendarModuleimports and<p-calendar>usage must be migrated toDatePickerModuleand<p-datePicker> - Found in:
dot-edit-content-calendar-fieldand other date input components
- All
-
Dropdown → Select
- All
DropdownModuleimports and<p-dropdown>usage must be migrated toSelectModuleand<p-select> - Extensively used throughout the codebase (experiments, content drive, analytics, etc.)
- All
-
TabView → Tabs
- All
TabViewModuleimports and<p-tabView>usage must be migrated toTabsModuleand<p-tabs> - Found in: experiments reports, edit content forms, and various portlets
- All
-
Sidebar → Drawer
- All
SidebarModuleimports and<p-sidebar>usage must be migrated toDrawerModuleand<p-drawer> - Found in: block editor sidebar, edit content sidebar, layout properties
- All
-
Messages → Message
- All
MessagesModuleimports and<p-messages>usage must be migrated toMessageModuleand<p-message> - Found in: EMA shell, analytics dashboard, global message components
- All
-
Chip → AutoComplete (for multiple selection)
- Review
ChipModuleusage - may need to use AutoComplete with multiple enabled - Found in: EMA page tools, experiments header
- Review
-
InputSwitch → ToggleSwitch
- All
InputSwitchModuleimports must be migrated toToggleSwitchModule - Check Storybook stories and component usage
- All
-
OverlayPanel → Popover
- All
OverlayPanelModuleimports must be migrated toPopoverModule - Found in: toolbar overlay components, Storybook stories
- All
-
pDefer → Angular @defer
- Replace PrimeNG's
pDeferdirective with Angular's native@defercontrol flow - Found in: Storybook stories
- Replace PrimeNG's
Additional Considerations
- API Changes: Review
primeng/apiimports for any deprecated interfaces or services - Styling: Verify PrimeFlex 3.3.1 compatibility with PrimeNG 20
- Module Imports: All module imports remain similar but verify import paths
- TypeScript Types: Check for any type changes in component props/events
Migration Strategy
Phase 1: Preparation
- Review PrimeNG 20 migration guide: https://primeng.org/guides/migration
- Audit all PrimeNG component usage in the codebase
- Create a comprehensive list of affected files
- Set up a feature branch for the migration
Phase 2: Dependency Updates
- Update
primengto version 20 inpackage.json - Update
primeiconsif required for PrimeNG 20 compatibility - Verify
primeflexcompatibility - Run
npm installand resolve any dependency conflicts
Phase 3: Component Migrations
- Migrate Calendar → DatePicker
- Migrate Dropdown → Select
- Migrate TabView → Tabs
- Migrate Sidebar → Drawer
- Migrate Messages → Message
- Review and migrate Chip usage
- Migrate InputSwitch → ToggleSwitch
- Migrate OverlayPanel → Popover
- Replace pDefer with Angular @defer
Phase 4: Testing
- Update all component unit tests
- Update Storybook stories
- Run E2E tests
- Manual QA testing of all affected features
- Visual regression testing
Phase 5: Documentation
- Update component documentation
- Update migration notes
- Update developer guidelines
Affected Areas
Based on codebase analysis, the following areas will be significantly affected:
- Edit Content Module: Calendar fields, dropdown selectors, tab views
- Block Editor: Sidebar components, dialogs
- Experiments Portlet: Tables, dropdowns, tabs, chips
- Content Drive: Multi-select, tree components
- Analytics: Dropdowns, calendars, messages
- EMA Editor: Sidebars, dialogs, messages
- UI Library: Various shared PrimeNG components
- Storybook: Multiple PrimeNG component stories
Resources
Notes
- This is a major version upgrade with breaking changes
- Consider creating a migration script or codemod for repetitive changes
- Plan for extensive testing across all affected features
- Coordinate with QA team for comprehensive testing
- Consider a phased rollout if possible
Reactions are currently unavailable
Sub-issues
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
In Progress