You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							14 lines
						
					
					
						
							407 B
						
					
					
				
			
		
		
	
	
							14 lines
						
					
					
						
							407 B
						
					
					
				// remove white spaces around operators when safe | 
						|
module.exports = function cleanWhitespace(node, item, list) { | 
						|
    if (node.value === '+' || node.value === '-') { | 
						|
        return; | 
						|
    } | 
						|
 | 
						|
    if (item.prev !== null && item.prev.data.type === 'WhiteSpace') { | 
						|
        list.remove(item.prev); | 
						|
    } | 
						|
 | 
						|
    if (item.next !== null && item.next.data.type === 'WhiteSpace') { | 
						|
        list.remove(item.next); | 
						|
    } | 
						|
};
 | 
						|
 |