src/options/space-before-closing-brace.js
function(ast) {
      let detected = [];

      ast.traverseByTypes(['block', 'atrulers'], function(node) {
        // For the block node, find its last (the deepest) child
        var whitespaceNode = getLastWhitespaceNode(node);
        if (whitespaceNode) {
          detected.push(whitespaceNode.content);
        } else {
          detected.push('');
        }
      });

      return detected;
    }
function(ast) {
      let detected = [];

      ast.traverseByTypes(['block', 'atrulers'], function(node) {
        // For the block node, find its last (the deepest) child
        var whitespaceNode = getLastWhitespaceNode(node);
        if (whitespaceNode) {
          detected.push(whitespaceNode.content);
        } else {
          detected.push('');
        }
      });

      return detected;
    }
function ( ast ) { let detected = [ ] ; ast . traverseByTypes ( [ 'block' , 'atrulers' ] , function ( node ) { // For the block node, find its last (the deepest) child var whitespaceNode = getLastWhitespaceNode ( node ) ; if ( whitespaceNode ) { detected . push ( whitespaceNode . content ) ; } else { detected . push ( '' ) ; } } ) ; return detected ; }
Detects the value of an option at the tree node.

@param {node} ast
Detects the value of an option at the tree node .