Vue introduces third-party plug-ins to prompt xx is not a function or xx is not define

clipboard.png

main.js

clipboard.png

.vue

clipboard.png

clipboard.png

how should I introduce
jquery is set

Mar.20,2021

import Zoomify from '../plugins/zoomify/zoomify'

make sure the path is correct at the same time


it is possible that this plug-in does not support a reference in the form of amd,cmd. You can look at the code in the plug-in. Add something like

if(typeof(module) !== 'undefined'){
    module.exports = window.;
}else if (typeof define === 'function'&& define.amd){
    define([],function () {
        'use strict'
        return window.;
    })
}

wrap it up and use it, as long as jq is installed correctly.


  1. libraries that are import or require must support CommonJS or even ES module, to use
  2. older libraries that do not support CommonJS, it is best to use < script > direct reference

I'm usually import 'library'
const variable name = window. The code below the variable name
can be called directly with the variable name or directly with the window. Variable name "call

"
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-1b30bdf-2aa81.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-1b30bdf-2aa81.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?