From 5da7d45e82a34c9b535c33f5c7d0ff5bbb8b3609 Mon Sep 17 00:00:00 2001 From: bqy_fe <1743369777@qq.com> Date: Tue, 13 Jul 2021 21:02:07 +0800 Subject: [PATCH] fix: :bug:custom component can not use vue lifecycle hooks --- .eslintrc.js | 4 +- index.html | 5 +- package.json | 14 +- preview/App.vue | 22 +- preview/index.html | 5 +- preview/views/comp-render.tsx | 17 +- src/packages/base-widgets/button/index.tsx | 2 +- src/packages/base-widgets/checkbox/index.tsx | 18 +- .../base-widgets/datetimePicker/index.tsx | 6 +- src/packages/base-widgets/divider/index.tsx | 11 +- src/packages/base-widgets/image/index.tsx | 4 +- src/packages/base-widgets/input/index.tsx | 6 +- src/packages/base-widgets/nav-bar/index.tsx | 25 +- .../base-widgets/notice-bar/index.tsx | 4 +- src/packages/base-widgets/picker/index.tsx | 79 ++-- src/packages/base-widgets/process/index.tsx | 4 +- src/packages/base-widgets/radio/index.tsx | 6 +- src/packages/base-widgets/rate/index.tsx | 6 +- src/packages/base-widgets/slider/index.tsx | 6 +- src/packages/base-widgets/stepper/index.tsx | 9 +- src/packages/base-widgets/swipe/index.tsx | 4 +- src/packages/base-widgets/switch/index.tsx | 6 +- src/packages/base-widgets/tabbar/index.tsx | 22 +- .../base-widgets/tabbar/tabbar-item.tsx | 6 +- src/packages/base-widgets/text/index.tsx | 4 +- .../container-component/form/index.tsx | 4 +- .../container-component/layout/index.tsx | 19 +- .../cross-sortable-options-editor.tsx | 12 +- .../simulator-editor/comp-render.tsx | 17 +- src/visual-editor/hooks/useVisualData.ts | 2 +- src/visual-editor/visual-editor.utils.ts | 4 +- yarn.lock | 364 +++++++++--------- 32 files changed, 381 insertions(+), 336 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 2c555f4..db6fdf9 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -22,9 +22,9 @@ module.exports = { 'plugin:prettier/recommended' ], rules: { - '@typescript-eslint/no-unused-vars': 'off', - 'no-unused-vars': 'off', 'vue/require-default-prop': 'off', + + '@typescript-eslint/no-unused-vars': 'off', '@typescript-eslint/ban-ts-comment': 'off', '@typescript-eslint/no-explicit-any': 'off', '@typescript-eslint/ban-types': 'off', diff --git a/index.html b/index.html index 30b2dbf..817ba28 100644 --- a/index.html +++ b/index.html @@ -3,7 +3,10 @@
- +