From a417bc8bea98ca9022560590732f8c34663b60d8 Mon Sep 17 00:00:00 2001 From: xiaohei <11674173+xiaohei102908@user.noreply.gitee.com> Date: Fri, 11 Aug 2023 11:04:20 +0800 Subject: [PATCH] 1 --- montier/.gitignore | 24 +++++++++++ montier/.vscode/extensions.json | 3 ++ montier/README.md | 18 ++++++++ montier/index.html | 13 ++++++ montier/package.json | 20 +++++++++ montier/public/vite.svg | 1 + montier/src/App.vue | 30 +++++++++++++ montier/src/assets/vue.svg | 1 + montier/src/components/HelloWorld.vue | 38 +++++++++++++++++ montier/src/main.ts | 5 +++ montier/src/style.css | 80 +++++++++++++++++++++++++++++++++++ montier/src/vite-env.d.ts | 1 + montier/tsconfig.json | 25 +++++++++++ montier/tsconfig.node.json | 10 +++++ montier/vite.config.ts | 7 +++ 15 files changed, 276 insertions(+) create mode 100644 montier/.gitignore create mode 100644 montier/.vscode/extensions.json create mode 100644 montier/README.md create mode 100644 montier/index.html create mode 100644 montier/package.json create mode 100644 montier/public/vite.svg create mode 100644 montier/src/App.vue create mode 100644 montier/src/assets/vue.svg create mode 100644 montier/src/components/HelloWorld.vue create mode 100644 montier/src/main.ts create mode 100644 montier/src/style.css create mode 100644 montier/src/vite-env.d.ts create mode 100644 montier/tsconfig.json create mode 100644 montier/tsconfig.node.json create mode 100644 montier/vite.config.ts diff --git a/montier/.gitignore b/montier/.gitignore new file mode 100644 index 0000000..a547bf3 --- /dev/null +++ b/montier/.gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/montier/.vscode/extensions.json b/montier/.vscode/extensions.json new file mode 100644 index 0000000..c0a6e5a --- /dev/null +++ b/montier/.vscode/extensions.json @@ -0,0 +1,3 @@ +{ + "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"] +} diff --git a/montier/README.md b/montier/README.md new file mode 100644 index 0000000..ef72fd5 --- /dev/null +++ b/montier/README.md @@ -0,0 +1,18 @@ +# Vue 3 + TypeScript + Vite + +This template should help get you started developing with Vue 3 and TypeScript in Vite. The template uses Vue 3 ` + + diff --git a/montier/package.json b/montier/package.json new file mode 100644 index 0000000..5c64f25 --- /dev/null +++ b/montier/package.json @@ -0,0 +1,20 @@ +{ + "name": "montier", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "vue-tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "vue": "^3.3.4" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^4.2.3", + "typescript": "^5.0.2", + "vite": "^4.4.5", + "vue-tsc": "^1.8.5" + } +} diff --git a/montier/public/vite.svg b/montier/public/vite.svg new file mode 100644 index 0000000..e7b8dfb --- /dev/null +++ b/montier/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/montier/src/App.vue b/montier/src/App.vue new file mode 100644 index 0000000..bb666a8 --- /dev/null +++ b/montier/src/App.vue @@ -0,0 +1,30 @@ + + + + + diff --git a/montier/src/assets/vue.svg b/montier/src/assets/vue.svg new file mode 100644 index 0000000..770e9d3 --- /dev/null +++ b/montier/src/assets/vue.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/montier/src/components/HelloWorld.vue b/montier/src/components/HelloWorld.vue new file mode 100644 index 0000000..7b25f3f --- /dev/null +++ b/montier/src/components/HelloWorld.vue @@ -0,0 +1,38 @@ + + + + + diff --git a/montier/src/main.ts b/montier/src/main.ts new file mode 100644 index 0000000..2425c0f --- /dev/null +++ b/montier/src/main.ts @@ -0,0 +1,5 @@ +import { createApp } from 'vue' +import './style.css' +import App from './App.vue' + +createApp(App).mount('#app') diff --git a/montier/src/style.css b/montier/src/style.css new file mode 100644 index 0000000..7294765 --- /dev/null +++ b/montier/src/style.css @@ -0,0 +1,80 @@ +:root { + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + line-height: 1.5; + font-weight: 400; + + color-scheme: light dark; + color: rgba(255, 255, 255, 0.87); + background-color: #242424; + + font-synthesis: none; + text-rendering: optimizeLegibility; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +a { + font-weight: 500; + color: #646cff; + text-decoration: inherit; +} +a:hover { + color: #535bf2; +} + +body { + margin: 0; + display: flex; + place-items: center; + min-width: 320px; + min-height: 100vh; +} + +h1 { + font-size: 3.2em; + line-height: 1.1; +} + +button { + border-radius: 8px; + border: 1px solid transparent; + padding: 0.6em 1.2em; + font-size: 1em; + font-weight: 500; + font-family: inherit; + background-color: #1a1a1a; + cursor: pointer; + transition: border-color 0.25s; +} +button:hover { + border-color: #646cff; +} +button:focus, +button:focus-visible { + outline: 4px auto -webkit-focus-ring-color; +} + +.card { + padding: 2em; +} + +#app { + max-width: 1280px; + margin: 0 auto; + padding: 2rem; + text-align: center; +} + +@media (prefers-color-scheme: light) { + :root { + color: #213547; + background-color: #ffffff; + } + a:hover { + color: #747bff; + } + button { + background-color: #f9f9f9; + } +} diff --git a/montier/src/vite-env.d.ts b/montier/src/vite-env.d.ts new file mode 100644 index 0000000..11f02fe --- /dev/null +++ b/montier/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/montier/tsconfig.json b/montier/tsconfig.json new file mode 100644 index 0000000..f82888f --- /dev/null +++ b/montier/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "preserve", + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true + }, + "include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/montier/tsconfig.node.json b/montier/tsconfig.node.json new file mode 100644 index 0000000..42872c5 --- /dev/null +++ b/montier/tsconfig.node.json @@ -0,0 +1,10 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true + }, + "include": ["vite.config.ts"] +} diff --git a/montier/vite.config.ts b/montier/vite.config.ts new file mode 100644 index 0000000..05c1740 --- /dev/null +++ b/montier/vite.config.ts @@ -0,0 +1,7 @@ +import { defineConfig } from 'vite' +import vue from '@vitejs/plugin-vue' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [vue()], +})