Skip to content

TS2693: 'Message' only refers to a type, but is being used as a value here #2

@rainmanhhh

Description

@rainmanhhh

在typescript中使用时报Message只是一个接口不能直接调它的方法
代码如下:
Message.alert('this is test', 'msg', {})

如何写d.ts将他同时定义为一个对象呢?就像Vue那样?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions