Skip to content

Commit b0c7540

Browse files
GaoNeng-wWwkagol
authored andcommitted
fix: 删除不必要的导入与声明
1 parent 16c6ce2 commit b0c7540

File tree

1 file changed

+0
-14
lines changed
  • packages/devui-vue/docs/.vitepress/demo

1 file changed

+0
-14
lines changed

packages/devui-vue/docs/.vitepress/demo/Demo.vue

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@
5353
import { useRoute, useData } from 'vitepress';
5454
import { throttle } from 'lodash';
5555
import copy from 'clipboard-copy';
56-
// import clipboardCopy from
5756
import {
5857
ref,
5958
computed,
@@ -63,18 +62,6 @@ import {
6362
nextTick,
6463
defineAsyncComponent
6564
} from 'vue';
66-
const clipboardCopy = async (text) => {
67-
try {
68-
await copyClipboardApi(text)
69-
} catch (err) {
70-
// ...Otherwise, use document.execCommand() fallback
71-
try {
72-
await copyExecCommand(text)
73-
} catch (err2) {
74-
throw err2 || err || makeError()
75-
}
76-
}
77-
}
7865
export default {
7966
name: 'Demo',
8067
props: {
@@ -162,7 +149,6 @@ export default {
162149
}
163150
164151
const onCopy = () => {
165-
// clipboardCopy(props.sourceCode)
166152
copy(props.sourceCode)
167153
isShowTip.value = true
168154
setTimeout(() => {

0 commit comments

Comments
 (0)