src/sass/parse.js
function getInterpolation() {
  const type = NodeType.InterpolationType;
  const token = tokens[pos];
  const line = token.ln;
  const column = token.col;
  let content = [];

  // Skip `#{`:
  pos += 2;

  while (pos < tokensLength &&
      tokens[pos].type !== TokenType.RightCurlyBracket) {
    const body = getArgument();
    if (typeof body.content === 'string') content.push(body);
    else content = content.concat(body);
  }

  const end = getLastPosition(content, line, column, 1);

  // Skip `}`:
  pos++;

  return newNode(type, content, line, column, end);
}
function getInterpolation() {
  const type = NodeType.InterpolationType;
  const token = tokens[pos];
  const line = token.ln;
  const column = token.col;
  let content = [];

  // Skip `#{`:
  pos += 2;

  while (pos < tokensLength &&
      tokens[pos].type !== TokenType.RightCurlyBracket) {
    const body = getArgument();
    if (typeof body.content === 'string') content.push(body);
    else content = content.concat(body);
  }

  const end = getLastPosition(content, line, column, 1);

  // Skip `}`:
  pos++;

  return newNode(type, content, line, column, end);
}
function getInterpolation ( ) { const type = NodeType . InterpolationType ; const token = tokens [ pos ] ; const line = token . ln ; const column = token . col ; let content = [ ] ; // Skip `#{`: pos += 2 ; while ( pos < tokensLength && tokens [ pos ] . type !== TokenType . RightCurlyBracket ) { const body = getArgument ( ) ; if ( typeof body . content === 'string' ) content . push ( body ) ; else content = content . concat ( body ) ; } const end = getLastPosition ( content , line , column , 1 ) ; // Skip `}`: pos ++ ; return newNode ( type , content , line , column , end ) ; }
Get node with an interpolated variable
@return {Array} `['interpolation', x]`
Get node with an interpolated variable