Skip to content

Commit bdc66c7

Browse files
committed
wip: revert helpers to compiler-only
1 parent faed989 commit bdc66c7

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

packages/runtime-core/src/apiSetupHelpers.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { shallowReadonly } from '@vue/reactivity'
21
import { getCurrentInstance, SetupContext } from './component'
32
import { EmitFn, EmitsOptions } from './componentEmits'
43
import { ComponentObjectPropsOptions, ExtractPropTypes } from './componentProps'
@@ -32,9 +31,7 @@ export function defineProps(props?: any) {
3231
`compiled away and passing it at runtime has no effect.`
3332
)
3433
}
35-
return __DEV__
36-
? shallowReadonly(getCurrentInstance()!.props)
37-
: getCurrentInstance()!.props
34+
return null as any
3835
}
3936

4037
export function defineEmit<
@@ -52,7 +49,7 @@ export function defineEmit(emitOptions?: any) {
5249
`compiled away and passing it at runtime has no effect.`
5350
)
5451
}
55-
return getCurrentInstance()!.emit
52+
return null as any
5653
}
5754

5855
export function useContext(): SetupContext {

0 commit comments

Comments
 (0)