Skip to content

Commit

Permalink
Merge pull request #3 from grtsinry43/main
Browse files Browse the repository at this point in the history
feat: 书写前端规范,解决已知问题
  • Loading branch information
grtsinry43 authored Jul 30, 2024
2 parents 21e19e3 + 6d3d204 commit cc9c996
Show file tree
Hide file tree
Showing 4 changed files with 417 additions and 27 deletions.
8 changes: 6 additions & 2 deletions .vitepress/config.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {defineConfig} from 'vitepress'
import {defineConfig} from 'vitepress';

// https://vitepress.dev/reference/site-config
export default defineConfig({
Expand All @@ -7,9 +7,13 @@ export default defineConfig({
titleTemplate: ':title - 升华工作室文档站',
description: "中南大学升华工作室的文档网站,包含代码规范,技术教学文档,项目文档等",
lastUpdated: true,
publicDir: 'public',
sitemap: {
hostname: 'https://docs.54sher.com'
},
themeConfig: {
// https://vitepress.dev/reference/default-theme-config
logo: 'logo.png',
logo: '/logo.png',
nav: [
{text: '主页', link: '/', activeMatch: '^/$'},
{text: '代码规范', link: '/styleguide/', activeMatch: '^/styleguide/'},
Expand Down
Binary file added public/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 6 additions & 1 deletion styleguide/index.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
# 代码规范

::: tip
这部分内容同步自 [Grtsinry43's Docs](https://docs.grtsinry43.com/)最后一次更新于2024-07-24。
这部分内容同步自 [Grtsinry43's Docs](https://docs.grtsinry43.com/)最后一次更新于 2024-07-24。
:::
::: info
这里是我个人的代码规范,参考了大型开源项目以及一些知名企业的开发规范,希望大家能够有所收获,也能不断完善这个规范。
:::

## 为什么要有代码规范?

首先当前的技术趋势都是前后端分离,我们要保证相互的协作开发,需要有详细的代码规范,这样才能保证代码的可读性,可维护性,可扩展性,可测试性等等。
其次,由于代码需要不断维护,不断调整迭代,必要时进行重构,所以我们需要有一套规范来保证代码的质量,减少代码的维护成本。
最后,学习代码规范也便于以后就业,学会了普遍的代码规范,对以后的工作 **(准确是和同事的交流和协作)** 也是有帮助的。

## 这里包含了什么?

首先是前后端(前端采用 `Vue.js`,后端采用 `SpringBoot``FastAPI`)的代码以及规范,
然后是数据库的设计规范,运维和产品的相关内容,最后是一些常用的工具的使用规范。
Loading

0 comments on commit cc9c996

Please sign in to comment.