|
1 |
| -import * as V from "./vue"; |
2 |
| -import * as Options from "./options"; |
3 |
| -import * as Plugin from "./plugin"; |
4 |
| -import * as VNode from "./vnode"; |
| 1 | +import { Vue } from "./vue"; |
5 | 2 |
|
6 |
| -// `Vue` in `export = Vue` must be a namespace |
7 |
| -// All available types are exported via this namespace |
8 |
| -declare namespace Vue { |
9 |
| - export type CreateElement = V.CreateElement; |
| 3 | +export default Vue; |
10 | 4 |
|
11 |
| - export type Component = Options.Component; |
12 |
| - export type AsyncComponent = Options.AsyncComponent; |
13 |
| - export type ComponentOptions<V extends Vue> = Options.ComponentOptions<V>; |
14 |
| - export type FunctionalComponentOptions = Options.FunctionalComponentOptions; |
15 |
| - export type RenderContext = Options.RenderContext; |
16 |
| - export type PropOptions = Options.PropOptions; |
17 |
| - export type ComputedOptions<V extends Vue> = Options.ComputedOptions<V>; |
18 |
| - export type WatchHandler<V extends Vue> = Options.WatchHandler<V, any>; |
19 |
| - export type WatchOptions = Options.WatchOptions; |
20 |
| - export type DirectiveFunction = Options.DirectiveFunction; |
21 |
| - export type DirectiveOptions = Options.DirectiveOptions; |
| 5 | +export { |
| 6 | + CreateElement |
| 7 | +} from "./vue"; |
22 | 8 |
|
23 |
| - export type PluginFunction<T> = Plugin.PluginFunction<T>; |
24 |
| - export type PluginObject<T> = Plugin.PluginObject<T>; |
| 9 | +export { |
| 10 | + Component, |
| 11 | + AsyncComponent, |
| 12 | + ComponentOptions, |
| 13 | + FunctionalComponentOptions, |
| 14 | + RenderContext, |
| 15 | + PropOptions, |
| 16 | + ComputedOptions, |
| 17 | + WatchHandler, |
| 18 | + WatchOptions, |
| 19 | + DirectiveFunction, |
| 20 | + DirectiveOptions |
| 21 | +} from "./options"; |
25 | 22 |
|
26 |
| - export type VNodeChildren = VNode.VNodeChildren; |
27 |
| - export type VNodeChildrenArrayContents = VNode.VNodeChildrenArrayContents; |
28 |
| - export type VNode = VNode.VNode; |
29 |
| - export type VNodeComponentOptions = VNode.VNodeComponentOptions; |
30 |
| - export type VNodeData = VNode.VNodeData; |
31 |
| - export type VNodeDirective = VNode.VNodeDirective; |
32 |
| -} |
| 23 | +export { |
| 24 | + PluginFunction, |
| 25 | + PluginObject |
| 26 | +} from "./plugin"; |
33 | 27 |
|
34 |
| -// TS cannot merge imported class with namespace, declare a subclass to bypass |
35 |
| -declare class Vue extends V.Vue {} |
36 |
| - |
37 |
| -export = Vue; |
| 28 | +export { |
| 29 | + VNodeChildren, |
| 30 | + VNodeChildrenArrayContents, |
| 31 | + VNode, |
| 32 | + VNodeComponentOptions, |
| 33 | + VNodeData, |
| 34 | + VNodeDirective |
| 35 | +} from "./vnode"; |
0 commit comments