vue-cli, if you want to introduce viz.js, download online js files, VS Code will prompt the js with ts syntax when it is imported locally, so that it cannot be packaged and run . But the introduction of online viz.js into index.html bypasses the packaging problem and works instead.
can also be run directly when importing the local js file through the script tag in a normal project.
guess that the problem may be on the packaging.
what module should be installed for vue-cli to package and execute the js file with ts syntax?
online version: < script src= " https://cdn.bootcss.com/viz.j.;></script>
will report an error whenever the local file appears. The local js file is copied from the online version.
ts
npmviz npm install viz -Snode_modules
index.js file? , fascinated