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(types): non-null assertion component name #16804

Merged
merged 2 commits into from
May 15, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/components/cascader-panel/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

CascaderPanel.install = (app: App): void => {
app.component(CascaderPanel.name, CascaderPanel)
app.component(CascaderPanel.name as string, CascaderPanel)
btea marked this conversation as resolved.
Show resolved Hide resolved
}

const _CascaderPanel = CascaderPanel as SFCWithInstall<typeof CascaderPanel>
Expand Down
2 changes: 1 addition & 1 deletion packages/components/cascader/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

Cascader.install = (app: App): void => {
app.component(Cascader.name, Cascader)
app.component(Cascader.name as string, Cascader)
}

const _Cascader = Cascader as SFCWithInstall<typeof Cascader>
Expand Down
2 changes: 1 addition & 1 deletion packages/components/collapse-transition/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

CollapseTransition.install = (app: App): void => {
app.component(CollapseTransition.name, CollapseTransition)
app.component(CollapseTransition.name as string, CollapseTransition)
}

const _CollapseTransition = CollapseTransition as SFCWithInstall<
Expand Down
2 changes: 1 addition & 1 deletion packages/components/date-picker/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import type { SFCWithInstall } from '@element-plus/utils'
const _DatePicker = DatePicker as SFCWithInstall<typeof DatePicker>

_DatePicker.install = (app: App) => {
app.component(_DatePicker.name, _DatePicker)
app.component(_DatePicker.name as string, _DatePicker)
}

export default _DatePicker
Expand Down
2 changes: 1 addition & 1 deletion packages/components/select-v2/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

Select.install = (app: App): void => {
app.component(Select.name, Select)
app.component(Select.name as string, Select)
}

const _Select = Select as SFCWithInstall<typeof Select>
Expand Down
2 changes: 1 addition & 1 deletion packages/components/time-picker/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export * from './src/common/props'
const _TimePicker = TimePicker as SFCWithInstall<typeof TimePicker>

_TimePicker.install = (app: App) => {
app.component(_TimePicker.name, _TimePicker)
app.component(_TimePicker.name as string, _TimePicker)
}

export { CommonPicker, TimePickPanel }
Expand Down
2 changes: 1 addition & 1 deletion packages/components/time-select/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

TimeSelect.install = (app: App): void => {
app.component(TimeSelect.name, TimeSelect)
app.component(TimeSelect.name as string, TimeSelect)
}

const _TimeSelect = TimeSelect as SFCWithInstall<typeof TimeSelect>
Expand Down
2 changes: 1 addition & 1 deletion packages/components/tree-select/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

TreeSelect.install = (app: App): void => {
app.component(TreeSelect.name, TreeSelect)
app.component(TreeSelect.name as string, TreeSelect)
}

const _TreeSelect = TreeSelect as SFCWithInstall<typeof TreeSelect>
Expand Down
2 changes: 1 addition & 1 deletion packages/components/tree/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { App } from 'vue'
import type { SFCWithInstall } from '@element-plus/utils'

Tree.install = (app: App): void => {
app.component(Tree.name, Tree)
app.component(Tree.name as string, Tree)
}

const _Tree = Tree as SFCWithInstall<typeof Tree>
Expand Down
Loading