chore(web-app): create new vue project to fix dependencies

This commit is contained in:
fastium
2025-03-31 13:04:39 +02:00
parent 627d1ac4c5
commit 4959d0fef2
7 changed files with 231 additions and 3589 deletions

View File

@@ -1,5 +0,0 @@
[*.{js,jsx,ts,tsx,vue}]
indent_style = space
indent_size = 2
trim_trailing_whitespace = true
insert_final_newline = true

View File

@@ -1,21 +1,11 @@
# web-app # web-app
## Installation
Install npm and NodeJS from [here](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm)
## Project setup ## Project setup
Install all dependencies of the npm project. It needs to have [Vue](https://cli.vuejs.org/guide/installation.html) in global
``` ```
sudo npm install -g @vue/cli
npm install npm install
``` ```
If you have any problem try the next command :
```
npm install ./ --legacy-peer-deps
```
### Compiles and hot-reloads for development ### Compiles and hot-reloads for development
Run a preview on localhost
``` ```
npm run serve npm run serve
``` ```
@@ -25,11 +15,5 @@ npm run serve
npm run build npm run build
``` ```
### Lints and fixes files
Run the linter integrated
```
npm run lint
```
### Customize configuration ### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/). See [Configuration Reference](https://cli.vuejs.org/config/).

3720
web-app/package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -4,43 +4,17 @@
"private": true, "private": true,
"scripts": { "scripts": {
"serve": "vue-cli-service serve", "serve": "vue-cli-service serve",
"build": "vue-cli-service build", "build": "vue-cli-service build"
"lint": "vue-cli-service lint"
}, },
"dependencies": { "dependencies": {
"vue": "^3.2.13", "axios": "^1.9.0",
"vue-class-component": "^8.0.0-0" "vue": "^3.2.13"
}, },
"devDependencies": { "devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.4.0",
"@typescript-eslint/parser": "^5.4.0",
"@vue/cli-plugin-eslint": "~5.0.0",
"@vue/cli-plugin-typescript": "~5.0.0", "@vue/cli-plugin-typescript": "~5.0.0",
"@vue/cli-service": "~5.0.0", "@vue/cli-service": "~5.0.0",
"@vue/eslint-config-standard": "^6.1.0",
"@vue/eslint-config-typescript": "^9.1.0",
"eslint": "^7.32.0",
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-promise": "^5.1.0",
"eslint-plugin-vue": "^8.0.3",
"typescript": "~4.5.5" "typescript": "~4.5.5"
}, },
"eslintConfig": {
"root": true,
"env": {
"node": true
},
"extends": [
"plugin:vue/vue3-essential",
"@vue/standard",
"@vue/typescript/recommended"
],
"parserOptions": {
"ecmaVersion": 2020
},
"rules": {}
},
"browserslist": [ "browserslist": [
"> 1%", "> 1%",
"last 2 versions", "last 2 versions",

View File

@@ -1,18 +1,31 @@
<template> <template>
<img alt="Vue logo" src="./assets/logo.png"> <img alt="Vue logo" src="./assets/logo.png" />
<HelloWorld msg="Welcome to Your Vue.js + TypeScript App"/> <HelloWorld msg="Welcome to Your Vue.js + TypeScript App" />
</template> </template>
<script lang="ts"> <script lang="ts">
import { Options, Vue } from 'vue-class-component' import { defineComponent } from "vue";
import HelloWorld from './components/HelloWorld.vue' import HelloWorld from "./components/HelloWorld.vue";
@Options({ import axios from "axios";
axios
.get("https://rest.mse.kb28.ch/ping")
.then(function (response) {
// handle success
console.log(response);
})
.catch(function (error) {
// handle error
console.error(error);
});
export default defineComponent({
name: "App",
components: { components: {
HelloWorld HelloWorld,
} },
}) });
export default class App extends Vue {}
</script> </script>
<style> <style>

View File

@@ -9,7 +9,6 @@
<h3>Installed CLI Plugins</h3> <h3>Installed CLI Plugins</h3>
<ul> <ul>
<li><a href="https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-typescript" target="_blank" rel="noopener">typescript</a></li> <li><a href="https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-typescript" target="_blank" rel="noopener">typescript</a></li>
<li><a href="https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-eslint" target="_blank" rel="noopener">eslint</a></li>
</ul> </ul>
<h3>Essential Links</h3> <h3>Essential Links</h3>
<ul> <ul>
@@ -31,16 +30,14 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { Options, Vue } from 'vue-class-component' import { defineComponent } from 'vue';
@Options({ export default defineComponent({
name: 'HelloWorld',
props: { props: {
msg: String msg: String,
} },
}) });
export default class HelloWorld extends Vue {
msg!: string
}
</script> </script>
<!-- Add "scoped" attribute to limit CSS to this component only --> <!-- Add "scoped" attribute to limit CSS to this component only -->

View File

@@ -6,7 +6,6 @@
"jsx": "preserve", "jsx": "preserve",
"importHelpers": true, "importHelpers": true,
"moduleResolution": "node", "moduleResolution": "node",
"experimentalDecorators": true,
"skipLibCheck": true, "skipLibCheck": true,
"esModuleInterop": true, "esModuleInterop": true,
"allowSyntheticDefaultImports": true, "allowSyntheticDefaultImports": true,