code: function getCartesianRange(props, axis) {
    // determine how to lay the axis and what direction positive and negative are
    const vertical = axis !== "x";
    const padding = getPadding(props);
    if (vertical) {
      return [props.height - padding.bottom, padding.top];
    }
    return [padding.left, props.width - padding.right];
  }
docs: Private Functions