fix:移除defineProps,defineEmits 两个全局宏命令引入,消除控制台警告

This commit is contained in:
落小梅 2022-02-05 20:05:16 +08:00
parent ef1c2b0f5a
commit b62f72baaf
54 changed files with 33 additions and 63 deletions

View File

@ -39,7 +39,7 @@
</template>
<script setup name="LaySelect" lang="ts">
import { defineProps, ref } from 'vue'
import { ref } from 'vue'
import { useRouter, useRoute } from 'vue-router'
import { Recordable } from '../../../src/module/type'

View File

@ -5,7 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
import "./index.less";
const props = defineProps<{

View File

@ -5,7 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
</script>
<template>

View File

@ -6,8 +6,6 @@ export default {
<script lang="ts" setup>
import {
defineProps,
defineEmits,
ref,
shallowRef,
withDefaults,

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps } from "vue";
import { computed } from "vue";
import "./index.less";
export interface LayBadgeProps {

View File

@ -5,7 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
import "./index.less";
const props = defineProps<{

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, provide, withDefaults } from "vue";
import { provide, withDefaults } from "vue";
const props = withDefaults(
defineProps<{

View File

@ -17,7 +17,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, inject, useSlots } from "vue";
import { inject, useSlots } from "vue";
const slot = useSlots();

View File

@ -7,7 +7,6 @@ export default {
<script setup lang="ts">
import {
withDefaults,
defineProps,
provide,
useSlots,
ref,

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, inject } from "vue";
import { inject } from "vue";
const props = defineProps<{
id: string;

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, inject } from "vue";
import { computed, inject } from "vue";
import "./index.less";
export interface LayCheckboxProps {

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, provide, ref, watch } from "vue";
import { provide, ref, watch } from "vue";
import { Recordable } from "../../types";
export interface LayCheckboxGroupProps {

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps } from "vue";
import { computed } from "vue";
const props = defineProps<{
md?: string;

View File

@ -7,10 +7,8 @@ export default {
<script setup lang="ts">
import {
withDefaults,
defineProps,
provide,
ref,
defineEmits,
watch,
} from "vue";

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { withDefaults, defineProps, inject, computed, ref } from "vue";
import { withDefaults, inject, computed, ref } from "vue";
const props = withDefaults(
defineProps<{

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps } from "vue";
import { computed } from "vue";
import "./index.less";
export interface LayContainerProps {

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, provide, ref, watch } from "vue";
import { provide, ref, watch } from "vue";
import { useClickOutside } from "@layui/hooks-vue";
const dropdownRef = ref<null | HTMLElement>(null);

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, withDefaults } from "vue";
import { withDefaults } from "vue";
import "./index.less";
export interface LayEmptyProps {

View File

@ -4,7 +4,7 @@ export default {
}
</script>
<script setup lang="ts">
import { defineProps, useSlots } from "vue";
import { useSlots } from "vue";
import "./index.less";
export interface LayDropdownProps {

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, useSlots } from "vue";
import { useSlots } from "vue";
const slot = useSlots();

View File

@ -7,7 +7,6 @@ export default {
<script setup lang="ts">
import "./index.less";
import {
defineProps,
inject,
withDefaults,
ref,

View File

@ -85,7 +85,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, Ref, ref } from "vue";
import { Ref, ref } from "vue";
import { LayIconList as icons } from "@layui/icons-vue";
export interface LayIconPickerProps {

View File

@ -5,8 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, defineEmits } from "vue";
export interface LayInputProps {
name?: string;
type?: string;

View File

@ -10,8 +10,6 @@ import layIcon from "../icon/index";
import layInput from "../input/index";
import "./index.less";
import {
defineProps,
defineEmits,
ref,
watch,
withDefaults,

View File

@ -5,8 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
const props = defineProps<{
theme?: string;
}>();

View File

@ -11,5 +11,4 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
</script>

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, provide } from "vue";
import { computed, provide } from "vue";
import "./index.less";
export interface LayMenuProps {

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, inject, Ref, useSlots } from "vue";
import { inject, Ref, useSlots } from "vue";
const slots = useSlots();

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, Ref, ref, watch, useSlots, computed } from "vue";
import { Ref, ref, watch, useSlots, computed } from "vue";
const slots = useSlots();

View File

@ -27,7 +27,6 @@ import {
CSSProperties,
ref,
watch,
defineEmits,
onMounted,
} from "vue";
import { on } from "../../utils/domUtil";

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps } from "vue";
import { computed } from "vue";
const props = defineProps<{
percent: number | string;

View File

@ -5,8 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, defineEmits } from "vue";
const props = defineProps<{
modelValue: string;
disabled?: boolean;

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, ref, withDefaults } from "vue";
import { computed, ref, withDefaults } from "vue";
import "./index.less";
export interface LayRateProps {

View File

@ -6,7 +6,7 @@ export default {
<script setup lang="ts">
import "./index.less";
import { defineProps, useSlots } from "vue";
import { useSlots } from "vue";
export interface LayResultProps {
title?: string;

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps } from "vue";
import { computed } from "vue";
import "./index.less";
export interface LayRowProps {

View File

@ -5,7 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
</script>
<template>

View File

@ -8,7 +8,6 @@ export default {
import "./index.less";
import LaySelectOption from "../selectOption/index.vue";
import {
defineProps,
provide,
isProxy,
ref,

View File

@ -7,7 +7,7 @@ export default {
<script setup lang="ts">
import LayCheckbox from "../checkbox";
import { SelectItem, SelectItemHandle, SelectItemPush } from "../../types";
import { computed, defineProps, inject, onMounted, Ref } from "vue";
import { computed, inject, onMounted, Ref } from "vue";
const props = withDefaults(
defineProps<{

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, CSSProperties } from "vue";
import { computed, CSSProperties } from "vue";
import "./index.less";
export interface LaySideProps {

View File

@ -7,7 +7,7 @@ export default {
<script setup lang="ts">
import LaySkeletonItem from '../skeletonItem/index.vue'
import './index.less'
import { defineProps, withDefaults} from "vue";
import { withDefaults} from "vue";
export interface LaySkeletonProps {
rows?: number;

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, withDefaults} from "vue";
import { withDefaults} from "vue";
export interface LaySkeletonProps {
type?: string;

View File

@ -102,7 +102,7 @@
</template>
<script setup lang="ts">
import { defineProps, Ref, ref, toRef } from "vue";
import { Ref, ref, toRef } from "vue";
import { on, off } from "evtd";
import "./index.less";

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { ref, watch, provide, defineProps, withDefaults, onMounted } from "vue";
import { ref, watch, provide, withDefaults, onMounted } from "vue";
import "./index.less";
//

View File

@ -13,7 +13,6 @@ import {
getCurrentInstance,
onBeforeUnmount,
reactive,
defineProps,
withDefaults,
watch,
} from "vue";

View File

@ -9,9 +9,7 @@ import {
ref,
watch,
provide,
defineProps,
withDefaults,
defineEmits,
} from "vue";
import "./index.less";

View File

@ -13,7 +13,6 @@ import {
getCurrentInstance,
onBeforeUnmount,
reactive,
defineProps,
withDefaults,
} from "vue";

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { computed, defineProps, inject, Ref, useSlots } from "vue";
import { computed, inject, Ref, useSlots } from "vue";
const slots = useSlots();

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, defineEmits, computed } from "vue";
import { computed } from "vue";
import "./index.less";
export interface LaySwitchProps {

View File

@ -7,7 +7,6 @@ export default {
<script setup lang="ts">
import tabItem from "../tabItem/index.vue";
import {
defineProps,
Component,
computed,
useSlots,

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { withDefaults, defineProps, inject, Ref } from "vue";
import { withDefaults, inject, Ref } from "vue";
const props = withDefaults(
defineProps<{

View File

@ -9,9 +9,7 @@ import {
ref,
watch,
useSlots,
defineProps,
withDefaults,
defineEmits,
onMounted,
} from "vue";
import { Recordable } from "../../types";

View File

@ -5,8 +5,6 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, defineEmits } from "vue";
export interface LayTextareaProps {
name?: string;
modelValue?: string;

View File

@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps, useSlots } from "vue";
import { useSlots } from "vue";
const slot = useSlots();

View File

@ -6,7 +6,7 @@ export default {
<script setup lang="ts">
import "./index.less";
import { defineProps, Ref, ref, useSlots, watch } from "vue";
import { Ref, ref, useSlots, watch } from "vue";
import { Recordable } from "../../types";
const slot = useSlots();