keep-alive exclude
时间: 2023-08-21 18:08:15 浏览: 91
keepalived
引用\[1\]中提到了keep-alive组件的exclude属性。exclude属性用于指定不需要被缓存的组件。在使用keep-alive组件时,可以通过exclude属性来排除某些组件不被缓存。例如,可以使用以下代码来排除名为"a"的组件不被缓存:
<keep-alive exclude="a">
<component />
</keep-alive>
这样,除了名为"a"的组件,其他组件都会被缓存起来。\[1\]
#### 引用[.reference_title]
- *1* [keep-alive用法(include、exclude、max)](https://blog.csdn.net/weixin_44813666/article/details/120737881)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^control_2,239^v3^insert_chatgpt"}} ] [.reference_item]
- *2* *3* [vue2.0 keep-alive 的 include和exclude使用](https://blog.csdn.net/qq_35220376/article/details/89879463)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^control_2,239^v3^insert_chatgpt"}} ] [.reference_item]
[ .reference_list ]
阅读全文