Skip to content

Commit

Permalink
fix: 修复 ts 类型
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyh2001 committed May 8, 2024
1 parent 99d6569 commit f8118e1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/fighting-design/_utils/tips/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @param { string } location 位置
* @param { string } message 警告信息
*/
export const warning = (location: string, message: string) => {
export const warning = (location: string, message: string): void => {
console.warn(`[fighting-design/${location}]: ${message}`)
}

Expand All @@ -16,7 +16,7 @@ export const warning = (location: string, message: string) => {
* @param { string } location 位置
* @param { string } message 警告信息
*/
export const error = (location: string, message: string) => {
export const error = (location: string, message: string): void => {
console.error(`[fighting-design/${location}]: ${message}`)
}

Expand All @@ -28,6 +28,6 @@ export const error = (location: string, message: string) => {
* @param { string } location 位置
* @param { string } message 警告信息
*/
export const throwError = (location: string, message: string) => {
export const throwError = (location: string, message: string): void => {
throw new Error(`[fighting-design/${location}]: ${message}`)
}

0 comments on commit f8118e1

Please sign in to comment.