diff --git a/example/main.tsx b/example/main.tsx
index f448a08..fe20ad0 100644
--- a/example/main.tsx
+++ b/example/main.tsx
@@ -1,17 +1,7 @@
import '@abraham/reflection'
import 'ant-design-vue/dist/reset.css'
-import {
- Component,
- type ComponentProps,
- Hook,
- injectService,
- Link,
- mergeRefs,
- Mut,
- provideService,
- VueComponent,
-} from 'vue3-oop'
-import { createApp, defineComponent, ref, shallowRef } from 'vue'
+import { Component, Hook, Link, mergeRefs, Mut, VueComponent } from 'vue3-oop'
+import { createApp, shallowRef } from 'vue'
import { ConfigProvider, Layout, Menu } from 'ant-design-vue'
import { RouterLink, RouterView } from 'vue-router'
import { RouterStartService } from './router'
@@ -19,50 +9,10 @@ import { routes } from './router/routes'
import zhCN from 'ant-design-vue/lib/locale/zh_CN'
import { setup } from './setup'
-class AService {
- height = ref(0)
-}
-
-const A1 = defineComponent(() => {
- provideService(new AService())
- return () => (
-
- )
-})
-
-const A2 = defineComponent(() => {
- const a = injectService(AService)
- console.log(11111, a)
- return () => 111 {a.height.value}
-})
-
-interface ChildProps {
- value?: string
- 'onUpdate:value'?: (val: string) => any
-}
-
-class Child extends VueComponent {
- static defaultProps: ComponentProps = ['value', 'onUpdate:value']
- @Hook('Mounted')
- mounted() {
- console.log('child mounted')
- }
- render() {
- console.log('child render')
- return child
- }
-}
-
@Component({
providers: [RouterStartService],
})
class App extends VueComponent {
- constructor(private a: RouterStartService) {
- super()
- }
-
@Mut() collapsed = false
cc = shallowRef()
@@ -93,11 +43,6 @@ class App extends VueComponent {
>
VUE 示例
- {
- console.log(value, refs)
- }}
- >