-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 379f4b2
Showing
52 changed files
with
15,067 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
.DS_Store | ||
dist | ||
*.local | ||
|
||
# Editor directories and files | ||
.idea | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 Li Jiayong | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#### 小A和小G的代码基地 | ||
<div style="width: 200px;"> | ||
![小程序码](https://raw.githubusercontent.com/CarefreeYong/AlgoGame/refs/heads/main/src/static/image/miniProgramCode.jpg) | ||
</div> | ||
|
||
#### AlgoGame | ||
一个基于 UniApp 框架开发的算法可视化与应用的项目。 | ||
|
||
#### 技术栈 | ||
UniApp、Vue3、TypeScript、TSX、Vite | ||
|
||
#### 兼容性 | ||
项目仅在微信小程序平台中开发与调试,其他平台不保证能正常运行 | ||
|
||
#### 安装依赖 | ||
推荐 | ||
```bash | ||
pnpm install | ||
``` | ||
或 | ||
```bash | ||
npm install | ||
``` | ||
|
||
#### 构建 | ||
推荐 | ||
```bash | ||
pnpm dev:mp-weixin | ||
``` | ||
或 | ||
```bash | ||
npm dev:mp-weixin | ||
``` | ||
|
||
#### 运行/调试 | ||
将 dist/dev/mp-weixin 文件夹导入到 [微信开发者工具](https://developers.weixin.qq.com/miniprogram/dev/devtools/stable.html) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
import jsLint from '@eslint/js' | ||
import tsLint from 'typescript-eslint' | ||
import vueLint from 'eslint-plugin-vue' | ||
import tsParser from '@typescript-eslint/parser' | ||
import vueParser from 'vue-eslint-parser' | ||
|
||
export default tsLint.config( | ||
jsLint.configs.recommended, | ||
...tsLint.configs.recommended, | ||
...vueLint.configs['flat/recommended'], | ||
{ | ||
ignores: ['dist', 'src/static'], // 该项要单独放才生效 | ||
}, | ||
{ | ||
files: ['**/*.{js,jsx,ts,tsx,d.ts,vue}'], | ||
languageOptions: { | ||
parser: vueParser, | ||
parserOptions: { | ||
parser: tsParser, | ||
sourceType: 'module', | ||
ecmaVersion: 2020, | ||
ecmaFeatures: { | ||
jsx: true, | ||
globalReturn: false, | ||
}, | ||
}, | ||
globals: { | ||
uni: 'readonly', | ||
}, | ||
}, | ||
rules: { | ||
indent: [ | ||
'error', | ||
4, | ||
{ | ||
SwitchCase: 1, | ||
}, | ||
], | ||
quotes: ['error', 'single'], | ||
semi: ['error', 'never'], | ||
'comma-dangle': ['error', 'always-multiline'], | ||
'arrow-spacing': [ | ||
'error', | ||
{ | ||
before: true, | ||
after: true, | ||
}, | ||
], | ||
'keyword-spacing': [ | ||
'error', | ||
{ | ||
before: true, | ||
after: true, | ||
}, | ||
], | ||
'switch-colon-spacing': [ | ||
'error', | ||
{ | ||
after: true, | ||
}, | ||
], | ||
'space-before-blocks': ['error', 'always'], | ||
'@typescript-eslint/ban-ts-comment': [ | ||
'error', | ||
{ | ||
'ts-ignore': false, | ||
}, | ||
], | ||
'@typescript-eslint/no-empty-object-type': [ | ||
'error', | ||
{ | ||
allowInterfaces: 'with-single-extends', | ||
}, | ||
], | ||
'@typescript-eslint/no-unused-expressions': 'off', | ||
'vue/html-indent': ['error', 4], | ||
'vue/html-self-closing': [ | ||
'error', | ||
{ | ||
html: { | ||
void: 'always', | ||
}, | ||
}, | ||
], | ||
'vue/no-v-text-v-html-on-component': 'off', | ||
'vue/attribute-hyphenation': ['error', 'never'], | ||
'vue/multi-word-component-names': [ | ||
'error', | ||
{ | ||
ignores: ['index', 'Dropdown'], | ||
}, | ||
], | ||
'vue/no-bare-strings-in-template': [ | ||
'error', | ||
{ | ||
allowlist: [], | ||
attributes: {}, | ||
directives: [], | ||
}, | ||
], | ||
'vue/singleline-html-element-content-newline': [ | ||
'error', | ||
{ | ||
ignoreWhenNoAttributes: false, | ||
}, | ||
], | ||
}, | ||
}, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<meta charset="UTF-8" /> | ||
<title></title> | ||
<script> | ||
const coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)')) | ||
document.write(`<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0${coverSupport ? ', viewport-fit=cover' : ''}" />`) | ||
</script> | ||
<!--preload-links--> | ||
<!--app-context--> | ||
</head> | ||
|
||
<body> | ||
<div id="app"><!--app-html--></div> | ||
<script type="module" src="/src/main.ts"></script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
{ | ||
"name": "algo-game", | ||
"description": "An algorithm visualization and application project developed with UniApp.", | ||
"version": "1.0.0", | ||
"author": "Li Jiayong <[email protected]> (https://github.com/CarefreeYong)", | ||
"license": "MIT", | ||
"type": "module", | ||
"scripts": { | ||
"dev:app": "uni -p app", | ||
"dev:app-android": "uni -p app-android", | ||
"dev:app-ios": "uni -p app-ios", | ||
"dev:app-harmony": "uni -p app-harmony", | ||
"dev:custom": "uni -p", | ||
"dev:h5": "uni", | ||
"dev:h5:ssr": "uni --ssr", | ||
"dev:mp-alipay": "uni -p mp-alipay", | ||
"dev:mp-baidu": "uni -p mp-baidu", | ||
"dev:mp-jd": "uni -p mp-jd", | ||
"dev:mp-kuaishou": "uni -p mp-kuaishou", | ||
"dev:mp-lark": "uni -p mp-lark", | ||
"dev:mp-qq": "uni -p mp-qq", | ||
"dev:mp-toutiao": "uni -p mp-toutiao", | ||
"dev:mp-weixin": "uni -p mp-weixin", | ||
"dev:mp-xhs": "uni -p mp-xhs", | ||
"dev:quickapp-webview": "uni -p quickapp-webview", | ||
"dev:quickapp-webview-huawei": "uni -p quickapp-webview-huawei", | ||
"dev:quickapp-webview-union": "uni -p quickapp-webview-union", | ||
"build:app": "uni build -p app", | ||
"build:app-android": "uni build -p app-android", | ||
"build:app-ios": "uni build -p app-ios", | ||
"build:app-harmony": "uni build -p app-harmony", | ||
"build:custom": "uni build -p", | ||
"build:h5": "uni build", | ||
"build:h5:ssr": "uni build --ssr", | ||
"build:mp-alipay": "uni build -p mp-alipay", | ||
"build:mp-baidu": "uni build -p mp-baidu", | ||
"build:mp-jd": "uni build -p mp-jd", | ||
"build:mp-kuaishou": "uni build -p mp-kuaishou", | ||
"build:mp-lark": "uni build -p mp-lark", | ||
"build:mp-qq": "uni build -p mp-qq", | ||
"build:mp-toutiao": "uni build -p mp-toutiao", | ||
"build:mp-weixin": "uni build -p mp-weixin", | ||
"build:mp-xhs": "uni build -p mp-xhs", | ||
"build:quickapp-webview": "uni build -p quickapp-webview", | ||
"build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei", | ||
"build:quickapp-webview-union": "uni build -p quickapp-webview-union", | ||
"type-check": "vue-tsc --noEmit", | ||
"lint": "eslint ./src/**/*.{js,jsx,ts,tsx,d.ts,vue} --no-cache" | ||
}, | ||
"dependencies": { | ||
"@dcloudio/uni-app": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-app-harmony": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-app-plus": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-components": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-h5": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-alipay": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-baidu": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-jd": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-kuaishou": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-lark": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-qq": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-toutiao": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-weixin": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-mp-xhs": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-quickapp-webview": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-ui": "^1.5.7", | ||
"vue": "^3.4.21" | ||
}, | ||
"devDependencies": { | ||
"@dcloudio/types": "^3.4.8", | ||
"@dcloudio/uni-automator": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-cli-shared": "3.0.0-4020920240930001", | ||
"@dcloudio/uni-stacktracey": "3.0.0-4020920240930001", | ||
"@dcloudio/vite-plugin-uni": "3.0.0-4020920240930001", | ||
"@eslint/js": "^9.14.0", | ||
"@types/eslint__js": "^8.42.3", | ||
"@typescript-eslint/parser": "^8.13.0", | ||
"@vitejs/plugin-vue-jsx": "^4.0.1", | ||
"@vue/runtime-core": "^3.4.21", | ||
"@vue/tsconfig": "^0.1.3", | ||
"eslint": "^9.14.0", | ||
"eslint-plugin-vue": "^9.30.0", | ||
"sass-embedded": "^1.80.6", | ||
"typescript": "^4.9.5", | ||
"typescript-eslint": "^8.12.2", | ||
"vite": "^5.4.10", | ||
"vue-eslint-parser": "^9.4.3", | ||
"vue-tsc": "^1.0.24" | ||
}, | ||
"engines": { | ||
"node": ">=16.0.0", | ||
"npm": ">=8.0.0", | ||
"pnpm": ">=8.0.0" | ||
}, | ||
"keywords": [ | ||
"uni-app", | ||
"vue3", | ||
"typescript", | ||
"tsx" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/CarefreeYong/AlgoGame.git" | ||
} | ||
} |
Oops, something went wrong.