Skip to content

Commit

Permalink
isNumber => typeof styleMinWidth === 'number'
Browse files Browse the repository at this point in the history
  • Loading branch information
komarovalexander committed Nov 7, 2020
1 parent 6527906 commit 80f3a40
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/lib/Utils/CellResizeUtils.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { isNumber } from 'util';

import { DispatchFunc } from '../types';

export const HeadCellResizeStateAction = 'HeadCellResizeStateAction';
Expand All @@ -26,7 +24,7 @@ export const getValidatedWidth = (newWidth: number, minWidth: number) => {
export const getMinWidth = (style: any): number => {
let minWidth: number = 20;
const styleMinWidth = style && style.minWidth;
if (styleMinWidth && isNumber(styleMinWidth)){
if (styleMinWidth && typeof styleMinWidth === 'number'){
minWidth = styleMinWidth;
}
return minWidth;
Expand Down

0 comments on commit 80f3a40

Please sign in to comment.