Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style: format code with Prettier and StandardJS #581

Closed
wants to merge 1 commit into from

Conversation

deepsource-autofix[bot]
Copy link
Contributor

This commit fixes the style issues introduced in a0dc9d3 according to the output
from Prettier and StandardJS.

Details: None

This commit fixes the style issues introduced in a0dc9d3 according to the output
from Prettier and StandardJS.

Details: None
Copy link

vercel bot commented Jan 23, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
pro-react-admin ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 23, 2025 0:14am

Copy link

Copy link

what-the-diff bot commented Jan 23, 2025

PR摘要

  • 统一了各个文件中的引号标准
    在多个文件中,将双引号统一改成了单引号,保持了代码的统一性。
  • src/components/stateless/FeatureAny/index.jsx文件中删除了末尾的逗号
    清理了对象的末尾的逗号,增强了代码的整洁度。
  • 修复了src/components/stateless/FeatureAny/index.jsx文件中一个缺少的结束括号
    data数组的最后一个对象后面添加了缺少的结束括号,修复了潜在的相应问题。
  • 清理了多个组件的JSX属性格式
    在如compareAll, textComponent, musicPlayer等多个组件中,JSX属性使用单引号的地方完成了清理。
  • src/components/stateless/CompareAll/index.jsx中,统一了函数定义的格式
    调整了mouseEnterHandlermouseLeaveHandler的空格使用,保持了函数定义的一致性。
  • 主要提高了代码格式和一致性,无显著功能性的改变

  • 为了一致性,更改了TagCloud和TextLoader组件中JSX的双引号为单引号
    保持了TagCloud和TextLoader组件的JSX代码中引号的一致性。
  • 简化了TagCloud组件中的return语句
    <div className={styles.mask}></div>的尾标签简化为<div className={styles.mask} />,简化了代码。
  • 统一了LoadingText组件中属性的格式
    添加了空格提高了代码的可读性。
  • 改善了demo页面的代码格式
    让object属性更紧凑,更易于阅读。
  • 优化了Echarts组件
    通过统一某些语法,如使用逗号和一致的optional chaining,增强了Echarts组件的一致性。
  • 修订了ReactPdf组件
    遵循代码库的一致的空格和格式化规范,修改了ReactPdf组件。

Copy link

Qodana for JS

455 new problems were found

Inspection name Severity Problems
ESLint 🔴 Failure 266
Unused local symbol 🔶 Warning 31
Unused import 🔶 Warning 21
Unnecessary non-capturing group 🔶 Warning 6
Redundant local variable 🔶 Warning 6
Mismatched JSDoc and function signature 🔶 Warning 4
Redundant character escape 🔶 Warning 3
Import can be shortened 🔶 Warning 2
Equality operator may cause type coercion 🔶 Warning 1
Unused assignment 🔶 Warning 1
Void function return value used 🔶 Warning 1
Pointless arithmetic expression 🔶 Warning 1
Duplicate character in character class 🔶 Warning 1
Unresolved JSX component ◽️ Notice 84
Result of method call returning a promise is ignored ◽️ Notice 12
Deprecated symbol used ◽️ Notice 10
Duplicated code fragment ◽️ Notice 2
Regular expression can be simplified ◽️ Notice 2
Missing await for an async function call ◽️ Notice 1

☁️ View the detailed Qodana report

Contact Qodana team

Contact us at [email protected]

@wkylin wkylin closed this Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant