Skip to content

提供一个方法来释放router实例。 #2942

@liuyang0826

Description

@liuyang0826

What problem does this feature solve?

当vue和single-spa这种微应用框架一起使用的时候,页面可能会有多个router实例,并且存在router实例需要被释放的场景。目前vue实例是可以正确的释放,但是router以及router创建的时候添加事件监听就不能得到释放,造成路由切换页面不响应和内存泄漏的问题。

What does the proposed API look like?

router.$destory() 类似这种即可。

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