mirror of
https://github.com/CorentinTh/it-tools.git
synced 2025-05-05 13:57:10 -04:00
|
||
---|---|---|
.. | ||
.github | ||
.vscode | ||
_templates/generator/ui-component | ||
locales | ||
public | ||
scripts | ||
src | ||
.dockerignore | ||
.eslintrc-auto-import.json | ||
.eslintrc.cjs | ||
.gitignore | ||
.nvmrc | ||
.prettierrc | ||
.versionrc | ||
auto-imports.d.ts | ||
CHANGELOG.md | ||
components.d.ts | ||
Dockerfile | ||
env.d.ts | ||
index.html | ||
LICENSE | ||
netlify.toml | ||
nginx.conf | ||
package.json | ||
playwright.config.ts | ||
pnpm-lock.yaml | ||
README.md | ||
renovate.json | ||
tsconfig.app.json | ||
tsconfig.json | ||
tsconfig.vite-config.json | ||
tsconfig.vitest.json | ||
unocss.config.ts | ||
vercel.json | ||
vite.config.ts |
对于开发人员和 IT 工作人员来说非常有用的工具。
[在线预览]
建议新工具
请前往 issues 提出新工具的想法,并查看列出的某些功能是否已实现。
指北
推荐的 IDE 设置
建议安装 VSCode 扩展:
- Volar (需要禁用 Vetur)
- TypeScript Vue Plugin (Volar).
- ESLint
- i18n Ally
建议的扩展设置:
{
"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"i18n-ally.localesPaths": ["locales", "src/tools/*/locales"],
"i18n-ally.keystyle": "nested"
}
TS 中对“.vue”导入的类型支持
默认情况下,TypeScript 无法处理“.vue”导入的类型信息,因此我们将“tsc”CLI 替换为“vue-tsc”来进行类型检查。 在编辑器中,我们需要 TypeScript Vue Plugin (Volar) 来使 TypeScript 语言服务识别 .vue
类型。
如果您觉得独立的 TypeScript 插件不够快,Volar 还实现了性能更高的接管模式。 您可以通过以下步骤启用它:
1.禁用内置的TypeScript扩展 1. 从 VSCode 的命令面板运行 “扩展:显示内置扩展” 2. 找到 “TypeScript 和 JavaScript 语言功能” ,右键单击并选择 “禁用(工作区)” 2. 通过从命令面板运行 “Developer: Reload Window” 来重新加载 VSCode 窗口。
下载
git clone https://gitee.com/angelofan/it-tools.git
安装依赖
cd it-tools
npm install
启动实时重载开发
npm run dev
编译
npm run build
使用 ESLint 进行检查
npm run lint
创建一个新工具
要创建新工具,有一个脚本可以生成新工具的样板文件,只需运行:
npm run script:create:tool your-tool-name
它将在 “src/tools” 中创建一个包含正确文件的目录,并在 “src/tools/index.ts” 中自动导入。您只需要将导入的工具添加到适当的类别中并开发该工具。
贡献
非常感谢所有已经做出贡献的人!
由作者 Corentin Thomasset 编写。
该项目使用 vercel.com 持续部署。
贡献者图是使用 contrib.rocks 生成的。