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

fix(webstorm): fix ts type prompt #563

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open

fix(webstorm): fix ts type prompt #563

wants to merge 7 commits into from

Conversation

liweijie0812
Copy link
Member

@liweijie0812 liweijie0812 commented Mar 1, 2025

vue 端 独立定义Typography 子组件

TypographyText
TypographyTitle
TypographyParagraph

@liweijie0812 liweijie0812 requested review from Copilot and removed request for chaishi, uyarn and anlyyao March 1, 2025 15:02

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Overview

This pull request fixes type formatting issues for the WebStorm environment by enhancing how TypeScript types are derived in the code.

  • Added export of formatType in packages/scripts/types/index.js
  • Modified packages/scripts/helper/index.js to compute and use formatted types via the new formatType function

Reviewed Changes

File Description
packages/scripts/types/index.js Exported formatType to be used by helper functions
packages/scripts/helper/index.js Updated type handling to use formatType's result for formatting

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

Comments suppressed due to low confidence (1)

packages/scripts/helper/index.js:118

  • The formatType function may return a primitive type (api.type) instead of an object with a 'type' property, causing rType.type to be undefined. Consider ensuring that formatType consistently returns an object with a 'type' property, or adjust the usage accordingly.
type: rType ? rType.type : api.field_type_text,
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