Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type Properties for FormSelection.vue. #19668

Open
jmchilton opened this issue Feb 20, 2025 · 0 comments
Open

Type Properties for FormSelection.vue. #19668

jmchilton opened this issue Feb 20, 2025 · 0 comments

Comments

@jmchilton
Copy link
Member

The lack of type on value in FormSelection.vue:

const props = defineProps({
    value: {
        default: null,
    },
    data: {
        type: Array,
        default: null,
    },
    display: {
        type: String,
        default: null,
    },
    optional: {
        type: Boolean,
        default: false,
    },
    options: {
        type: Array,
        default: null,
    },
    multiple: {
        type: Boolean,
        default: false,
    },
});

does not play well proper typing of Vue typescript. It might be a rabbit hole to start typing these form components.

src/components/Form/Elements/FormData/FormData.vue:705:13 - error TS2322: Type 'DataOption[] | undefined' is not assignable to type 'null | undefined'.
  Type 'DataOption[]' is not assignable to type 'null | undefined'.

705             v-model="currentValue"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant