Skip to content

Commit cc5926f

Browse files
committed
chore: remove unused error codes
1 parent 55a9d6c commit cc5926f

File tree

1 file changed

+1
-23
lines changed

1 file changed

+1
-23
lines changed

packages/reactivity/src/errorHandling.ts

+1-23
Original file line numberDiff line numberDiff line change
@@ -5,43 +5,21 @@ import { LifecycleHooks } from './enums'
55
// contexts where user provided function may be executed, in addition to
66
// lifecycle hooks.
77
export enum ErrorCodes {
8-
SETUP_FUNCTION,
9-
RENDER_FUNCTION,
108
WATCH_GETTER,
119
WATCH_CALLBACK,
1210
WATCH_CLEANUP,
13-
NATIVE_EVENT_HANDLER,
14-
COMPONENT_EVENT_HANDLER,
15-
VNODE_HOOK,
16-
DIRECTIVE_HOOK,
17-
TRANSITION_HOOK,
1811
APP_ERROR_HANDLER,
19-
APP_WARN_HANDLER,
20-
FUNCTION_REF,
21-
ASYNC_COMPONENT_LOADER,
2212
SCHEDULER,
2313
}
2414

2515
export const ErrorTypeStrings: Record<LifecycleHooks | ErrorCodes, string> = {
2616
[LifecycleHooks.ACTIVATED]: 'activated hook',
2717
[LifecycleHooks.DEACTIVATED]: 'deactivated hook',
28-
[ErrorCodes.SETUP_FUNCTION]: 'setup function',
29-
[ErrorCodes.RENDER_FUNCTION]: 'render function',
3018
[ErrorCodes.WATCH_GETTER]: 'watcher getter',
3119
[ErrorCodes.WATCH_CALLBACK]: 'watcher callback',
3220
[ErrorCodes.WATCH_CLEANUP]: 'watcher cleanup function',
33-
[ErrorCodes.NATIVE_EVENT_HANDLER]: 'native event handler',
34-
[ErrorCodes.COMPONENT_EVENT_HANDLER]: 'component event handler',
35-
[ErrorCodes.VNODE_HOOK]: 'vnode hook',
36-
[ErrorCodes.DIRECTIVE_HOOK]: 'directive hook',
37-
[ErrorCodes.TRANSITION_HOOK]: 'transition hook',
3821
[ErrorCodes.APP_ERROR_HANDLER]: 'app errorHandler',
39-
[ErrorCodes.APP_WARN_HANDLER]: 'app warnHandler',
40-
[ErrorCodes.FUNCTION_REF]: 'ref function',
41-
[ErrorCodes.ASYNC_COMPONENT_LOADER]: 'async component loader',
42-
[ErrorCodes.SCHEDULER]:
43-
'scheduler flush. This is likely a Vue internals bug. ' +
44-
'Please open an issue at https://github.com/vuejs/core .',
22+
[ErrorCodes.SCHEDULER]: 'scheduler flush',
4523
}
4624

4725
export type ErrorTypes = LifecycleHooks | ErrorCodes

0 commit comments

Comments
 (0)