init project
This commit is contained in:
20
examples/Root.vue
Normal file
20
examples/Root.vue
Normal file
@@ -0,0 +1,20 @@
|
||||
<template>
|
||||
<div class="root">
|
||||
hello world
|
||||
</div>
|
||||
<popup />
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { Popup } from "common4web";
|
||||
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.root {
|
||||
width: 80%;
|
||||
|
||||
.sp {
|
||||
height: 520px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
10
examples/main.ts
Normal file
10
examples/main.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { createApp } from "vue";
|
||||
import Root from "./Root.vue";
|
||||
import common4Web, { axios, VPopup } from "common4web"; // 本地开发
|
||||
|
||||
axios.defaults.baseURL = "http://localhost:8091";
|
||||
|
||||
const app = createApp(Root);
|
||||
app.use(common4Web);
|
||||
app.directive("popup", VPopup);
|
||||
app.mount("#root");
|
||||
7
examples/vite-env.d.ts
vendored
Normal file
7
examples/vite-env.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
declare module "*.vue" {
|
||||
import type { DefineComponent } from "vue";
|
||||
const component: DefineComponent<{}, {}, any>;
|
||||
export default component;
|
||||
}
|
||||
|
||||
declare module "prismjs";
|
||||
Reference in New Issue
Block a user