You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
835 B

3 months ago
  1. import { createApp } from 'vue'
  2. import { onMounted, ref, reactive,h } from 'vue';
  3. import { createWebHashHistory, createRouter } from 'vue-router'
  4. import App from './App.vue'
  5. import Antd from 'ant-design-vue';
  6. import TestFeeder from './components/TestFeeder.vue';
  7. import TestTubePreProcess from './components/TestTubePreProcess.vue';
  8. import './style/app.css'
  9. const router = createRouter({
  10. history: createWebHashHistory(),
  11. routes: [
  12. { name: 'feeder', path: '/feeder', component: TestFeeder },
  13. { name: 'tube-pre-process', path: '/tube-pre-process', component: TestTubePreProcess },
  14. ],
  15. })
  16. let app = createApp(App)
  17. // 创建一个全局响应式对象
  18. const pageRefCnt = ref(1);
  19. // 使用 provide 提供全局状态
  20. app.provide('pageRefCnt', pageRefCnt);
  21. app.use(router);
  22. app.use(Antd);
  23. app.mount('#app')