v-bar
v-bar copied to clipboard
Uncaught SyntaxError: Unexpected token <
I met a problem when I use v-bar with [email protected]. It is like this:
/Users/wuyiqing/Desktop/data-manager-front-end/node_modules/v-bar/src/components/v-bar.vue:1
Uncaught SyntaxError: Unexpected token <
at Object.exports.runInThisContext (vm.js:78)
at Module._compile (module.js:543)
at Object.Module._extensions..js (module.js:580)
at Module.load (module.js:488)
at tryModuleLoad (module.js:447)
at Function.Module._load (module.js:439)
at Module.require (module.js:498)
at require (internal/module.js:20)
at eval (webpack-internal:///90:1)
at Object.<anonymous> (renderer.js:1281)
At first, I thought it was because of the version of vue. But it was not work when I changed the Vue to 2.3.3.
Hi @chhpt!
No one else are report the same issue yet. I will try reproduce and I give you feedback soon...
I got the same issue with Nuxt.js. Scrollbar works as expected but my console has the warning:
[vue-router] Failed to resolve async component default: SyntaxError: Unexpected token <
[vue-router] uncaught error during route navigation:
/Users/xxx/xxx/xxx xxx/xxx-xxx/node_modules/v-bar/src/components/v-bar.vue:1
(function (exports, require, module, __filename, __dirname) { <style scoped lang="sass">
^
SyntaxError: Unexpected token <
at createScript (vm.js:74:10)
at Object.runInThisContext (vm.js:116:10)
at Module._compile (module.js:537:28)
at Object.Module._extensions..js (module.js:584:10)
at Module.load (module.js:507:32)
at tryModuleLoad (module.js:470:12)
at Function.Module._load (module.js:462:3)
at Module.require (module.js:517:17)
at require (internal/module.js:11:18)
at r (/Users/xxx/xxx/xxx xxx/xxx-xxx/node_modules/vue-server-renderer/build.js:7758:16)
at Object.<anonymous> (server-bundle.js:4359:18)
at __webpack_require__ (server-bundle.js:27:30)
at Object.108 (pages/index/signIn.2a00ee66685cbbeda3ef.js:10:64)
at __webpack_require__ (server-bundle.js:27:30)
at Object.78 (pages/index/signIn.2a00ee66685cbbeda3ef.js:359:285)
at __webpack_require__ (server-bundle.js:27:30)
the module needs to be compiled with vue-loader to work in an ssr environment