How does Vue introduce a js file written by itself?

for example, the code is as follows:

components.js

import Vue from "vue"
import { Grid, GridItem } from "vux"

Vue.component("grid", Grid)
Vue.component("grid-item", GridItem)
...
...
...

how to main.js the above js file in the vue-cli project. There is no export statement in the above js file.

Mar.05,2021

import { AlertPlugin, ConfirmPlugin } from 'vux'
    
Vue.use(ConfirmPlugin)
Vue.use(ToastPlugin)

.


Vue.component is used to register global components,
so you can directly import this module

import '/path/to/components.js'

usage instructions:

Import a module only for side effects
import a module only for side effects of the module, without importing anything in the module. This runs the global code in the module, but does not actually import any values.
For more information, please see MDN

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e39bd2-44555.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e39bd2-44555.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?