feat(types/script-setup): add generic type to defineExpose (#5035)
This commit is contained in:
		
							parent
							
								
									f73547fc05
								
							
						
					
					
						commit
						34985fee6b
					
				@ -118,7 +118,7 @@ export function defineEmits() {
 | 
			
		||||
 * This is only usable inside `<script setup>`, is compiled away in the
 | 
			
		||||
 * output and should **not** be actually called at runtime.
 | 
			
		||||
 */
 | 
			
		||||
export function defineExpose(exposed?: Record<string, any>) {
 | 
			
		||||
export function defineExpose<Exposed extends Record<string, any> = Record<string, any>>(exposed?: Exposed) {
 | 
			
		||||
  if (__DEV__) {
 | 
			
		||||
    warnRuntimeUsage(`defineExpose`)
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user