add bootstrap and recreate Vue project

This commit is contained in:
Thomas Peetz
2025-08-12 11:32:51 +02:00
parent 60d314abaf
commit 83338df181
14 changed files with 457 additions and 468 deletions
+21 -16
View File
@@ -1,7 +1,5 @@
# kontor-vue # kontor-vue
### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/).
This template should help get you started developing with Vue 3 in Vite. This template should help get you started developing with Vue 3 in Vite.
## Recommended IDE Setup ## Recommended IDE Setup
@@ -12,25 +10,26 @@ This template should help get you started developing with Vue 3 in Vite.
TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types. TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types.
## Project setup ## Customize configuration
```
See [Vite Configuration Reference](https://vite.dev/config/).
## Project Setup
```sh
npm install npm install
``` ```
### Compiles and hot-reloads for development ### Compile and Hot-Reload for Development
```
npm run serve
```
### Compiles and minifies for production
```
npm run build
```
### Lint with [ESLint](https://eslint.org/)
```sh ```sh
npm run lint npm run dev
```
### Type-Check, Compile and Minify for Production
```sh
npm run build
``` ```
### Run Unit Tests with [Vitest](https://vitest.dev/) ### Run Unit Tests with [Vitest](https://vitest.dev/)
@@ -54,3 +53,9 @@ But it's still recommended to test the production build with `test:e2e` before d
npm run build npm run build
npm run test:e2e npm run test:e2e
``` ```
### Lint with [ESLint](https://eslint.org/)
```sh
npm run lint
```
-5
View File
@@ -1,5 +0,0 @@
module.exports = {
presets: [
'@vue/cli-plugin-babel/preset'
]
}
+1 -1
View File
@@ -1,5 +1,5 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang=""> <html lang="de">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<link rel="icon" href="/favicon.ico"> <link rel="icon" href="/favicon.ico">
-19
View File
@@ -1,19 +0,0 @@
{
"compilerOptions": {
"target": "es5",
"module": "esnext",
"baseUrl": "./",
"moduleResolution": "node",
"paths": {
"@/*": [
"src/*"
]
},
"lib": [
"esnext",
"dom",
"dom.iterable",
"scripthost"
]
}
}
+432 -383
View File
File diff suppressed because it is too large Load Diff
+1 -2
View File
@@ -20,7 +20,7 @@
"format": "prettier --write src/" "format": "prettier --write src/"
}, },
"dependencies": { "dependencies": {
"pinia": "^3.0.3", "bootstrap-vue": "^2.23.1",
"vue": "^3.5.18", "vue": "^3.5.18",
"vue-router": "^4.5.1" "vue-router": "^4.5.1"
}, },
@@ -29,7 +29,6 @@
"@types/jsdom": "^21.1.7", "@types/jsdom": "^21.1.7",
"@types/node": "^22.16.5", "@types/node": "^22.16.5",
"@vitejs/plugin-vue": "^6.0.1", "@vitejs/plugin-vue": "^6.0.1",
"@vitejs/plugin-vue-jsx": "^5.0.1",
"@vitest/eslint-plugin": "^1.3.4", "@vitest/eslint-plugin": "^1.3.4",
"@vue/eslint-config-prettier": "^10.2.0", "@vue/eslint-config-prettier": "^10.2.0",
"@vue/eslint-config-typescript": "^14.6.0", "@vue/eslint-config-typescript": "^14.6.0",
-17
View File
@@ -1,17 +0,0 @@
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title><%= htmlWebpackPlugin.options.title %></title>
</head>
<body>
<noscript>
<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
+2
View File
@@ -1,5 +1,6 @@
<script setup lang="ts"> <script setup lang="ts">
import { RouterLink, RouterView } from 'vue-router' import { RouterLink, RouterView } from 'vue-router'
import HelloWorld from './components/HelloWorld.vue'
</script> </script>
<template> <template>
@@ -7,6 +8,7 @@ import { RouterLink, RouterView } from 'vue-router'
<img alt="Vue logo" class="logo" src="@/assets/logo.svg" width="125" height="125" /> <img alt="Vue logo" class="logo" src="@/assets/logo.svg" width="125" height="125" />
<div class="wrapper"> <div class="wrapper">
<HelloWorld msg="You did it!" />
<nav> <nav>
<RouterLink to="/">Home</RouterLink> <RouterLink to="/">Home</RouterLink>
Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.7 KiB

-4
View File
@@ -1,4 +0,0 @@
import { createApp } from 'vue'
import App from './App.vue'
createApp(App).mount('#app')
-3
View File
@@ -1,14 +1,11 @@
import './assets/main.css' import './assets/main.css'
import { createApp } from 'vue' import { createApp } from 'vue'
import { createPinia } from 'pinia'
import App from './App.vue' import App from './App.vue'
import router from './router' import router from './router'
const app = createApp(App) const app = createApp(App)
app.use(createPinia())
app.use(router) app.use(router)
app.mount('#app') app.mount('#app')
-12
View File
@@ -1,12 +0,0 @@
import { ref, computed } from 'vue'
import { defineStore } from 'pinia'
export const useCounterStore = defineStore('counter', () => {
const count = ref(0)
const doubleCount = computed(() => count.value * 2)
function increment() {
count.value++
}
return { count, doubleCount, increment }
})
-2
View File
@@ -2,14 +2,12 @@ import { fileURLToPath, URL } from 'node:url'
import { defineConfig } from 'vite' import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue' import vue from '@vitejs/plugin-vue'
import vueJsx from '@vitejs/plugin-vue-jsx'
import vueDevTools from 'vite-plugin-vue-devtools' import vueDevTools from 'vite-plugin-vue-devtools'
// https://vite.dev/config/ // https://vite.dev/config/
export default defineConfig({ export default defineConfig({
plugins: [ plugins: [
vue(), vue(),
vueJsx(),
vueDevTools(), vueDevTools(),
], ],
resolve: { resolve: {
-4
View File
@@ -1,4 +0,0 @@
const { defineConfig } = require('@vue/cli-service')
module.exports = defineConfig({
transpileDependencies: true
})