[Vue warn]: Failed to resolve component:

Hello,

I am new with Vue and I am trying to use it with Django.
My first step was fine, I could easely add compoent in my Django project.
Then I repeat my task to have a leaflet map in my first page. I have been helped with Vue Leaflet

I added a component to have my map shown, but sadely, that component genrate an error

[Vue warn]: Failed to resolve component:carte

I googled by no way to find a similar strcture with Django. I hope you can help me.

As it’s my first message, I can not add several link, then I just add a link to github in order to see my latest code here.

My steps
As you can see, in map/static/js/vuejs/component / created a second component named ‘carte’

If now, you look at templates/base.html, I added the following
<script type="module" src="{% static 'js/vuejs/component/carte.js' %}"></script>

I needed to add type="module" otherwise I added this error

Uncaught SyntaxError: import declarations may only appear at top level of a module

Q1. Did I do well? There were another solution than adding type="module"?

For now I kept type="module". In my file /map/templates/map/field.html I added <carte></carte> to attach the component. But sadly, it look like the tag can not be matched to my component and I guess that the reason why I get this error

Vue warn]: Failed to resolve component: carte
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
at

Then, as I am using Vuejs in Django, I do not know how to solve this issue. Do you have any idea?

Ayn suggestion will help me a lot as I already spent all the evening (yesrterday)

Many thanks

After looking on that problem, I guess this must be solve first
Uncaught SyntaxError: import declarations may only appear at top level of a module

Most of the example as you can see here (Hello, Map) use import as you can see here

I really wonder why, the import generate a such error while Vue is used with Django

Thanks