Skip to content

Commit a86aca8

Browse files
committed
[Feature][Engine UI] upgrade framework;upgrade vite to 5;add vitest dependency;
1 parent 55f071b commit a86aca8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+4255
-2637
lines changed

seatunnel-engine/seatunnel-engine-ui/.env.development

+2-1
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,5 @@
1515

1616
NODE_ENV=development
1717

18-
VITE_APP_DEV_WEB_URL='http://124.221.211.72:5801'
18+
VITE_APP_API_SERVICE='http://124.221.211.72:5801'
19+
VITE_APP_API_BASE='/hazelcast/rest/maps'

seatunnel-engine/seatunnel-engine-ui/.eslintignore

-18
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/* eslint-env node */
2+
require('@rushstack/eslint-patch/modern-module-resolution')
3+
4+
module.exports = {
5+
root: true,
6+
'extends': [
7+
'plugin:vue/vue3-essential',
8+
'eslint:recommended',
9+
'@vue/eslint-config-typescript',
10+
'@vue/eslint-config-prettier/skip-formatting'
11+
],
12+
overrides: [
13+
{
14+
files: [
15+
'cypress/e2e/**/*.{cy,spec}.{js,ts,jsx,tsx}',
16+
'cypress/support/**/*.{js,ts,jsx,tsx}'
17+
],
18+
'extends': [
19+
'plugin:cypress/recommended'
20+
]
21+
}
22+
],
23+
parserOptions: {
24+
ecmaVersion: 'latest'
25+
}
26+
}

seatunnel-engine/seatunnel-engine-ui/.eslintrc.js

-71
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,30 @@
1-
# Licensed to the Apache Software Foundation (ASF) under one or more
2-
# contributor license agreements. See the NOTICE file distributed with
3-
# this work for additional information regarding copyright ownership.
4-
# The ASF licenses this file to You under the Apache License, Version 2.0
5-
# (the "License"); you may not use this file except in compliance with
6-
# the License. You may obtain a copy of the License at
7-
#
8-
# http://www.apache.org/licenses/LICENSE-2.0
9-
#
10-
# Unless required by applicable law or agreed to in writing, software
11-
# distributed under the License is distributed on an "AS IS" BASIS,
12-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13-
# See the License for the specific language governing permissions and
14-
# limitations under the License.
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
159

16-
.vscode
17-
.idea
10+
node_modules
1811
.DS_Store
19-
12+
dist
13+
dist-ssr
14+
coverage
2015
*.local
21-
*.swp
22-
*.tgz
23-
*.tsbuildinfo
2416

25-
dist
26-
node_modules
27-
package-lock.json
17+
/cypress/videos/
18+
/cypress/screenshots/
2819

29-
.pnpm-debug.log
20+
# Editor directories and files
21+
.vscode/*
22+
!.vscode/extensions.json
23+
.idea
24+
*.suo
25+
*.ntvs*
26+
*.njsproj
27+
*.sln
28+
*.sw?
29+
30+
*.tsbuildinfo

seatunnel-engine/seatunnel-engine-ui/.prettierignore

-18
This file was deleted.

seatunnel-engine/seatunnel-engine-ui/.prettierrc.js

-30
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"$schema": "https://json.schemastore.org/prettierrc",
3+
"semi": false,
4+
"tabWidth": 2,
5+
"singleQuote": true,
6+
"printWidth": 100,
7+
"trailingComma": "none"
8+
}
Original file line numberDiff line numberDiff line change
@@ -1 +1,61 @@
1-
# Apache SeaTunnel Engine UI
1+
# seatunnel-engine-ui
2+
3+
This template should help get you started developing with Vue 3 in Vite.
4+
5+
## Recommended IDE Setup
6+
7+
[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur).
8+
9+
## Type Support for `.vue` Imports in TS
10+
11+
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.
12+
13+
## Customize configuration
14+
15+
See [Vite Configuration Reference](https://vitejs.dev/config/).
16+
17+
## Project Setup
18+
19+
```sh
20+
pnpm install
21+
```
22+
23+
### Compile and Hot-Reload for Development
24+
25+
```sh
26+
pnpm dev
27+
```
28+
29+
### Type-Check, Compile and Minify for Production
30+
31+
```sh
32+
pnpm build
33+
```
34+
35+
### Run Unit Tests with [Vitest](https://vitest.dev/)
36+
37+
```sh
38+
pnpm test:unit
39+
```
40+
41+
### Run End-to-End Tests with [Cypress](https://www.cypress.io/)
42+
43+
```sh
44+
pnpm test:e2e:dev
45+
```
46+
47+
This runs the end-to-end tests against the Vite development server.
48+
It is much faster than the production build.
49+
50+
But it's still recommended to test the production build with `test:e2e` before deploying (e.g. in CI environments):
51+
52+
```sh
53+
pnpm build
54+
pnpm test:e2e
55+
```
56+
57+
### Lint with [ESLint](https://eslint.org/)
58+
59+
```sh
60+
pnpm lint
61+
```
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import { defineConfig } from 'cypress'
2+
3+
export default defineConfig({
4+
e2e: {
5+
specPattern: 'cypress/e2e/**/*.{cy,spec}.{js,jsx,ts,tsx}',
6+
baseUrl: 'http://localhost:4173'
7+
}
8+
})
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// https://on.cypress.io/api
2+
3+
describe('My First Test', () => {
4+
it('visits the app root url', () => {
5+
cy.visit('/')
6+
cy.contains('h1', 'You did it!')
7+
})
8+
})
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "@vue/tsconfig/tsconfig.dom.json",
3+
"include": ["./**/*", "../support/**/*"],
4+
"compilerOptions": {
5+
"isolatedModules": false,
6+
"types": ["cypress"]
7+
}
8+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"name": "Using fixtures to represent data",
3+
"email": "[email protected]",
4+
"body": "Fixtures are a great way to mock data for responses to routes"
5+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
/// <reference types="cypress" />
2+
// ***********************************************
3+
// This example commands.ts shows you how to
4+
// create various custom commands and overwrite
5+
// existing commands.
6+
//
7+
// For more comprehensive examples of custom
8+
// commands please read more here:
9+
// https://on.cypress.io/custom-commands
10+
// ***********************************************
11+
//
12+
//
13+
// -- This is a parent command --
14+
// Cypress.Commands.add('login', (email, password) => { ... })
15+
//
16+
//
17+
// -- This is a child command --
18+
// Cypress.Commands.add('drag', { prevSubject: 'element'}, (subject, options) => { ... })
19+
//
20+
//
21+
// -- This is a dual command --
22+
// Cypress.Commands.add('dismiss', { prevSubject: 'optional'}, (subject, options) => { ... })
23+
//
24+
//
25+
// -- This will overwrite an existing command --
26+
// Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... })
27+
//
28+
// declare global {
29+
// namespace Cypress {
30+
// interface Chainable {
31+
// login(email: string, password: string): Chainable<void>
32+
// drag(subject: string, options?: Partial<TypeOptions>): Chainable<Element>
33+
// dismiss(subject: string, options?: Partial<TypeOptions>): Chainable<Element>
34+
// visit(originalFn: CommandOriginalFn, url: string, options: Partial<VisitOptions>): Chainable<Element>
35+
// }
36+
// }
37+
// }
38+
39+
export {}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// ***********************************************************
2+
// This example support/index.js is processed and
3+
// loaded automatically before your test files.
4+
//
5+
// This is a great place to put global configuration and
6+
// behavior that modifies Cypress.
7+
//
8+
// You can change the location of this file or turn off
9+
// automatically serving support files with the
10+
// 'supportFile' configuration option.
11+
//
12+
// You can read more here:
13+
// https://on.cypress.io/configuration
14+
// ***********************************************************
15+
16+
// Import commands.js using ES2015 syntax:
17+
import './commands'
18+
19+
// Alternatively you can use CommonJS syntax:
20+
// require('./commands')
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/// <reference types="vite/client" />

0 commit comments

Comments
 (0)