mirror of
				https://github.com/Unleash/unleash.git
				synced 2025-10-27 11:02:16 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			11 lines
		
	
	
		
			204 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			11 lines
		
	
	
		
			204 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| 'use strict';
 | |
| 
 | |
| const filter = (key, value) => {
 | |
|     if (!key || !value) return array => array;
 | |
|     return array => array.filter(item => item[key].startsWith(value));
 | |
| };
 | |
| 
 | |
| module.exports = {
 | |
|     filter,
 | |
| };
 |