Skip to content

Conflicts with globally defined components #9

@LeBenLeBen

Description

@LeBenLeBen

When you have globally defined components, for example in your main.js:

import Vue from 'vue';
import { ValidationObserver } from 'vee-validate';

Vue.component('ValidationObserver', ValidationObserver);

And you use one of these in combination with an auto-loaded component from the plugin in the same component:

<template>
  <ValidationObserver>
    <FiltersForm>
      <!-- ... -->
    </FiltersForm>
  </ValidationObserver>
</template>

Vue warns about custom element ValidationObserver not being available. Removing FiltersForm or disabling the plugin and specifying the components explicitly works.

If I check vm.$options.component of the component above, I only get FiltersForm. It’s like something override globally defined component, or prevent them from being found when parsing the template.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions