frzi / swiftui-router

Path-based routing in SwiftUI
MIT License
919 stars 44 forks source link

change clear historyStack to removeSubrange #13

Closed gsgtzq closed 4 years ago

gsgtzq commented 4 years ago

I changed HistoryData clear function.

I think Cleaning historyStack requires retaining the root routing and returning to the initialization, otherwise canGoBack will need two routing jumps to return true, this is a bug.

frzi commented 4 years ago

Good catch. Thanks!