Skip to content

Commit

Permalink
fix: history-transition component: add key in router-view
Browse files Browse the repository at this point in the history
  • Loading branch information
barrier committed Apr 8, 2022
1 parent 04a546c commit c6e4a95
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "history-keep-alive",
"version": "0.1.8",
"version": "0.1.9",
"description": "vue plugin: keep alive like a native app, according to vue-router history",
"main": "dist/index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/components/the-transition/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ export default {
aliveKey={this.aliveKey}
max={this.max}
>
<router-view ref={this.aliveRef} />
<router-view ref={this.aliveRef} key={this.aliveKey} />
</history-base-keep-alive>
) : (<router-view ref={this.aliveRef} />)
}
Expand Down

0 comments on commit c6e4a95

Please sign in to comment.