From 9fd632324e7ea55252c6ddbefebf6214c7a95804 Mon Sep 17 00:00:00 2001 From: wxsm Date: Wed, 22 Sep 2021 19:33:35 +0800 Subject: [PATCH] remove unnecessary space --- src/api/special-attributes.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/special-attributes.md b/src/api/special-attributes.md index 961b57a6cd..e5222d1584 100644 --- a/src/api/special-attributes.md +++ b/src/api/special-attributes.md @@ -2,7 +2,7 @@ ## key -- **Expects:** `number | string | symbol ` +- **Expects:** `number | string | symbol` The `key` special attribute is primarily used as a hint for Vue's virtual DOM algorithm to identify VNodes when diffing the new list of nodes against the old list. Without keys, Vue uses an algorithm that minimizes element movement and tries to patch/reuse elements of the same type in-place as much as possible. With keys, it will reorder elements based on the order change of keys, and elements with keys that are no longer present will always be removed/destroyed.