function printWhitespace(path, value, proseWrap, isLink) {
  if (proseWrap === "preserve" && value === "\n") {
    return hardline;
  }

  const canBeSpace =
    value === " " ||
    (value === "\n" && lineBreakCanBeConvertedToSpace(path, isLink));

  if (isBreakable(path, value, proseWrap, isLink)) {
    return canBeSpace ? line : softline;
  }

  return canBeSpace ? " " : "";
}
@param {AstPath} path
@param {WhitespaceValue} value
@param {ProseWrap} proseWrap
@param {boolean} [isLink] Special mode of (un)wrapping that preserves the
normalized form of link labels. https://spec.commonmark.org/0.30/#matches