Carlos Cifuentes
AngularJS library migration · dashboard grid

Migrating angular-gridster to modern Angular

angular-gridster laid out dashboard widgets on a grid where users could drag and resize them. It is tied to AngularJS.

What replaces it

OptionWhen to choose it
angular-gridster2Closest match: the same grid of draggable, resizable items, written for Angular.
gridstackFramework-agnostic dashboard grid that ships an Angular wrapper.
CSS GridWhen users no longer rearrange the dashboard and the layout is fixed.

How to migrate it

  1. Find where layouts are saved (per user or per role, in the backend or in localStorage) and in which format.
  2. Migrate each widget to a standalone component with inputs, and render the widgets dynamically from the layout data.
  3. Write a converter from the saved layouts to the new item format and run it when a layout is loaded.

Watch out. Saved layouts are the trap. angular-gridster items use sizeX, sizeY, row and col, while angular-gridster2 uses x, y, cols and rows; without a converter every user loses the dashboard they arranged.

Other libraries

Planning a migration or a micro-frontend platform?

In a 20-minute call you describe your situation and I tell you how I'd approach it. If it isn't worth doing yet, I'll say so.

Message me on LinkedIn