Reputation: 81
Using PrimeNG 5.2.5 there seems to be an issue with resizable columns. If I want the ability to toggle the feature on and off you can't because of the pResizableColumn directive that is added to the template. Even if you set the p-table [resizableColumns]="false" the resize handles still show up because of the pResizableColumn directive. Is there a way to toggle a directive attribute in Angular 5 easily?
basically I want this:
<ng-template>
<tr>
<th pResizableColumn> ...
to be:
<ng-template>
<tr>
<th> ...
by toggling a variable? Is there a good way to do this without repeating the block and adding an *ngIf to it?
Upvotes: 2
Views: 2315
Reputation: 81
looks like there is an input to disable it. If you use:
[pResizableColumnDisabled]="true"
it will disable the column resizing.
Upvotes: 6