Skip to content

Migration Guide for Templates

Cagatay Civici edited this page Apr 30, 2024 · 4 revisions

This guide covers updating templates up to version 17, PrimeNG v18 will have a new theming system.

Migration an application template to a newer version of PrimeNG requires updating the PrimeNG version and the designer folder to align the theme.

1) PrimeNG Version

Open package.json and update the PrimeNG dependency. For updating Angular, visit the angular update guide.

"primeng": "x.y.z"

2) SASS Theme

Visit the primeng-sass-theme and download the release that matches the PrimeNG version. Extract the contents of the bundle copy the theme-base folder, and update the theme-base folder at /src/assets/layout/styles/theme/theme-base with the new content. The final structure should be like the following;

  • /src/assets/layout/styles/theme/theme-base
    • _colors.scss
    • _common.scss _ _components.scss
    • _mixins.scss _ components

3) Compile SASS

Final step is compiling the SASS to generate CSS. Install SASS if you do not have sass at command line.

sass --update src/assets:src/assets

If you receive compilation errors, it may be due to missing SASS variables. In this case add the missing variables and compile again.

4) Support

Visit the PrimeNG Templates Forum to create a ticket for assistance.