mirror of
				https://github.com/optim-enterprises-bv/vault.git
				synced 2025-11-03 20:17:59 +00:00 
			
		
		
		
	* removes on click modifier from LinkTo elements * adds changelog * reverts button changes and closes dropdown in next tick of runloop * removes comment
		
			
				
	
	
		
			21 lines
		
	
	
		
			541 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			541 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
#!/usr/bin/env node
 | 
						|
/* eslint-env node */
 | 
						|
 | 
						|
// print to console all files that include LinkTo elements using the {{on modifier}}
 | 
						|
module.exports = (env) => {
 | 
						|
  let fileAlerted;
 | 
						|
  return {
 | 
						|
    ElementNode(node) {
 | 
						|
      if (node.tag === 'LinkTo') {
 | 
						|
        if (!fileAlerted) {
 | 
						|
          const usesModifier = node.modifiers.find((modifier) => modifier.path.original === 'on');
 | 
						|
          if (usesModifier) {
 | 
						|
            console.log(env.filePath); // eslint-disable-line
 | 
						|
            fileAlerted = true;
 | 
						|
          }
 | 
						|
        }
 | 
						|
      }
 | 
						|
    },
 | 
						|
  };
 | 
						|
};
 |