feat: adapt Vue 3.x (#755)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
Zen
2023-05-05 13:57:35 +08:00
committed by GitHub
parent 84c36c5c68
commit fa9eef757a
5 changed files with 54 additions and 29 deletions
+14
View File
@@ -0,0 +1,14 @@
// Copyright 2017-2023 @polkadot/vue-identicon authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { version } from 'vue';
export function adaptVNodeAttrs (data: Record<string, any>) {
if (version.startsWith('3.')) {
return data;
} else {
return {
attrs: data
};
}
}