I'm currently diving into Vue and am interested in incorporating vue-tabs into my project.
The guidelines for globally "installing" it are as follows:
//in your app.js or a similar file
// import Vue from 'vue'; // Already available
import VueTabs from 'vue-nav-tabs';
Vue.component('tabs', Tabs);
Vue.component('tab', Tab);
However, I've encountered an issue with the import
statement, specifically in Chrome 66. It seems that VueTabs
is defined as a top-level var
within vue-tabs.js
:
import VueTabs
Uncaught SyntaxError: Unexpected identifier
It's possible that some of the information above might not be entirely accurate. As I navigate my way through the fundamentals of modern web development, I'd appreciate a more simplified explanation of whether or not this approach is feasible and why. Most resources I come across assume knowledge of pre-compilation and build processes.
For now, I prefer to steer clear of using npm
, webpack
, or yarn
in order to focus solely on working with Vue
. I enjoy the simplicity of being able to utilize Vue
by downloading vue.js
locally and including it via a straightforward <script>
tag.
I attempted using
<script https://...vue-tabs.js>
, but unfortunately had no success similar to when using Vue
.Is there a way to implement
vue-tabs
in the same manner, or will some form of pre-compilation or build process ultimately be necessary?