src/client/components/PlainMarkdownInput/slate/tokenizer.js
function getHeaderContent(tokens, type, markup) {
  if (tokens[1].children.length === 0) {
    tokens[1].children.push(getEmptyText());
  } else if (tokens[1].children[0].type !== 'text') {
    tokens[1].children.unshift(getEmptyText());
  }
  const content = changeText(tokens[1].children, markup);
  return {
    type,
    content,
    length: getTokensLength(content)
  };
}
function getHeaderContent(tokens, type, markup) {
  if (tokens[1].children.length === 0) {
    tokens[1].children.push(getEmptyText());
  } else if (tokens[1].children[0].type !== 'text') {
    tokens[1].children.unshift(getEmptyText());
  }
  const content = changeText(tokens[1].children, markup);
  return {
    type,
    content,
    length: getTokensLength(content)
  };
}
function getHeaderContent ( tokens , type , markup ) { if ( tokens [ 1 ] . children . length === 0 ) { tokens [ 1 ] . children . push ( getEmptyText ( ) ) ; } else if ( tokens [ 1 ] . children [ 0 ] . type !== 'text' ) { tokens [ 1 ] . children . unshift ( getEmptyText ( ) ) ; } const content = changeText ( tokens [ 1 ] . children , markup ) ; return { type , content , length : getTokensLength ( content ) } ; }
getHeaderContent - Function create content for header-token

@param tokens
@param type
@param markup
@returns {{type: *, content}}
getHeaderContent - Function create content for header - token