Add Prettier config and update code style
This commit is contained in:
17
.prettierrc.cjs
Normal file
17
.prettierrc.cjs
Normal file
@ -0,0 +1,17 @@
|
||||
module.exports = {
|
||||
singleQuote: true, // 使用单引号
|
||||
printWidth: 100,
|
||||
tabWidth: 2,
|
||||
useTabs: false,
|
||||
semi: false,
|
||||
vueIndentScriptAndStyle: true,
|
||||
quoteProps: 'as-needed',
|
||||
bracketSpacing: true,
|
||||
arrowParens: 'always',
|
||||
insertPragma: false,
|
||||
requirePragma: false,
|
||||
trailingComma: 'es5',
|
||||
proseWrap: 'never',
|
||||
htmlWhitespaceSensitivity: 'strict',
|
||||
endOfLine: 'auto'
|
||||
}
|
||||
1
app.vue
1
app.vue
@ -8,5 +8,4 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import zhCn from 'element-plus/es/locale/lang/zh-cn'
|
||||
</script>
|
||||
|
||||
@ -13,6 +13,7 @@ export const useToken = () =>
|
||||
vipLevel: number | undefined,
|
||||
sex: number | undefined,
|
||||
}
|
||||
/** 用户信息 */
|
||||
export const useUserInfo = () => useState<UserInfo>('userInfo', () => {
|
||||
return {
|
||||
nickname: '',
|
||||
|
||||
Reference in New Issue
Block a user