packages/@interactjs/utils/rect.ts
Consider simplifying this complex logical expression. Open
Open
if (rect && !('x' in rect && 'y' in rect)) {
rect = extend({}, rect)
rect.x = rect.left || 0
rect.y = rect.top || 0
Consider simplifying this complex logical expression. Open
Open
if (rect && !('left' in rect && 'top' in rect)) {
rect = extend({}, rect)
rect.left = rect.x || 0
rect.top = rect.y || 0