"bookmark" 布局的方法

Approach for "bookmark" layout

我不太确定在 Web 开发中是否将这种东西称为 'bookmark' 布局。我会在下面的屏幕上解释。

我想实现这样的目标,但不知道如何实现。有人能指出我应该在哪里锚定吗?我在网上找不到任何东西/可能是在使用错误的短语。

这个组件将是应用程序的一部分,在我们推送到路由器路径后,它将显示这种布局。基本上我可以实现这个购买继续为每个页面推送不同的路由,但是如果这些页面属于 "one model comoponent" 我不想在切换它们时一直重新加载它们,只是在我们进入每个页面后一次.它会像移动应用程序中的标签栏一样工作 (iOS)。

在许多 UI 上下文(例如浏览器、macOS 应用程序等)和 Web 开发中,您所谓的“书签布局”简称为 tabs(如 iOS 你也提到的标签栏)。

I wouldn't like to reload them all of the time while switching them

Vue 为您提供内置组件 <keep-alive> 用于此类用例:

When wrapped around a dynamic component, <keep-alive> caches the inactive component instances without destroying them.

查看 Vue 指南:https://vuejs.org/v2/guide/components-dynamic-async.html#keep-alive-with-Dynamic-Components

When switching between these components though, you’ll sometimes want to maintain their state or avoid re-rendering for performance reasons. […]

To solve this problem, we can wrap our dynamic component with a <keep-alive> element