Skip to content

Commit

Permalink
Add startings of vue ui for users
Browse files Browse the repository at this point in the history
  • Loading branch information
NHAS committed Nov 29, 2024
1 parent 67dcf79 commit ad66488
Show file tree
Hide file tree
Showing 38 changed files with 7,994 additions and 0 deletions.
6 changes: 6 additions & 0 deletions internal/mfaportal/resources/frontend/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[*.{js,jsx,mjs,cjs,ts,tsx,mts,cts,vue}]
charset = utf-8
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
41 changes: 41 additions & 0 deletions internal/mfaportal/resources/frontend/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/* eslint-env node */
require('@rushstack/eslint-patch/modern-module-resolution')

module.exports = {
root: true,
'extends': [
'plugin:vue/vue3-essential',
'eslint:recommended',
'@vue/eslint-config-typescript',
'@vue/eslint-config-prettier/skip-formatting',
'plugin:import/recommended',
'plugin:import/typescript',
],
parserOptions: {
ecmaVersion: 'latest'
},
env: {
browser: true,
node: true
},
rules: {
'vue/multi-word-component-names': 0 ,
'import/order': ['error', {
'newlines-between': 'always',
pathGroups: [
{ pattern: '@/components/**', group: 'internal', position: 'before' },
{ pattern: '@/api/**', group: 'internal', position: 'before' },
{ pattern: '@/composables/**', group: 'internal', position: 'before' },
{ pattern: '@/stores/**', group: 'internal', position: 'before' },
{ pattern: '@/util/**', group: 'internal', position: 'before' },
]
}],
'import/newline-after-import': 'error',
'import/first': 'error'
},
settings: {
'import/resolver': {
typescript: true
},
},
}
30 changes: 30 additions & 0 deletions internal/mfaportal/resources/frontend/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
.DS_Store
dist
dist-ssr
coverage
*.local

/cypress/videos/
/cypress/screenshots/

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

*.tsbuildinfo
8 changes: 8 additions & 0 deletions internal/mfaportal/resources/frontend/.vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"recommendations": [
"Vue.volar",
"dbaeumer.vscode-eslint",
"EditorConfig.EditorConfig",
"esbenp.prettier-vscode"
]
}
39 changes: 39 additions & 0 deletions internal/mfaportal/resources/frontend/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# frontend

This template should help get you started developing with Vue 3 in Vite.

## Recommended IDE Setup

[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur).

## Type Support for `.vue` Imports in TS

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.

## Customize configuration

See [Vite Configuration Reference](https://vite.dev/config/).

## Project Setup

```sh
npm install
```

### Compile and Hot-Reload for Development

```sh
npm run dev
```

### Type-Check, Compile and Minify for Production

```sh
npm run build
```

### Lint with [ESLint](https://eslint.org/)

```sh
npm run lint
```
1 change: 1 addition & 0 deletions internal/mfaportal/resources/frontend/env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="vite/client" />
12 changes: 12 additions & 0 deletions internal/mfaportal/resources/frontend/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Wag</title>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>
Loading

0 comments on commit ad66488

Please sign in to comment.