mirror of
				https://github.com/vector-im/element-web.git
				synced 2025-10-31 08:11:16 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			21 lines
		
	
	
		
			463 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			463 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| /* A dummy React component which we use for stubbing out app-level components
 | |
|  */
 | |
| 
 | |
| import React from 'react';
 | |
| import createReactClass from 'create-react-class';
 | |
| 
 | |
| export default function(opts) {
 | |
|     opts = opts || {};
 | |
|     if (!opts.displayName) {
 | |
|         opts.displayName = 'StubComponent';
 | |
|     }
 | |
| 
 | |
|     if (!opts.render) {
 | |
|         opts.render = function() {
 | |
|             return <div>{ this.displayName }</div>;
 | |
|         };
 | |
|     }
 | |
| 
 | |
|     return createReactClass(opts);
 | |
| }
 |