This issue as been imported as question since it does not respect nuxt.js issue template. Only bug reports and feature requests stays open to reduce maintainers workload.
If your issue is not a question, please mention the repo admin or moderator to change its type and it will be re-opened automatically.
Your question is available at https://cmty.app/nuxt/nuxt.js/issues/c8420.
+1 same issue, when I use ssr mode for nuxt.js i got error on main page:
Unexpected token import (Missing stack frames)
Please anyone help us to solve this problem.
"vue": "^2.5.17",
"nuxt": "^2.3.2",
npx create a new project and then run yarn dev
Unexpected identifier
vm.js
Missing stack frames
npx create a new project and then run
yarn dev
Unexpected identifier vm.js Missing stack frames
The same here..
Having the same problem for newly created project. This seems to solve the problem for the time https://github.com/nuxt/nuxt.js/issues/5822
@jdsans its not about bootstrap. 'coz i don't even use it.
@willin I was having this issue with vue2-google-maps
and I fixed it by changing my plugin configuration so that it's only loaded client-side:
// plugins/googlemaps.js
import Vue from 'vue'
import * as VueGoogleMaps from 'vue2-google-maps'
Vue.use(VueGoogleMaps, {
load: {
key: 'my_key',
libraries: 'places',
}
})
// nuxt.config.js
export default {
// snip
plugins: [
{ ssr: false, src: '~plugins/googlemaps.js' }
]
// snip
}
mode: 'client' is work too
// nuxt.config.js
export default {
plugins: [
{ src: '~plugins/googlemaps.js', mode: 'client' }
]
}
Note: Since Nuxt.js 2.4, mode has been introduced as option of plugins to specify plugin type, possible value are: client or server. ssr: false will be adapted to mode: 'client' and deprecated in next major release.
@jcsky
I am using vue2-google-maps and my nuxt project has nuxt 2.13
I am still getting the same error please help
plugins: [
{
src: "~/plugins/onload.api.js",
mode: "server"
},
{
src: "~/plugins/onload.component.js",
mode: "client"
},
{
src: "~/plugins/onload.client.js",
mode: "client"
},
{
src: "~/plugins/gmap.js",
mode: "client"
}
]
@jcsky
I am using vue2-google-maps and my nuxt project has nuxt 2.13I am still getting the same error please help
plugins: [ { src: "~/plugins/onload.api.js", mode: "server" }, { src: "~/plugins/onload.component.js", mode: "client" }, { src: "~/plugins/onload.client.js", mode: "client" }, { src: "~/plugins/gmap.js", mode: "client" } ]
https://github.com/xkjyeah/vue-google-maps/issues/498#issuecomment-429566868
@manniL
The problem occurs only when the page is reload.
this is my plugin gmap.js
import Vue from "vue";
import * as VueGoogleMaps from "vue2-google-maps";
Vue.use(VueGoogleMaps, {
load: {
key: "APIKEY"
}
});
this the nuxt.config.js
plugins: [
{
src: "~/plugins/gmap.js",
mode: "client"
}
],
build: {
transpile: [/^vue2-google-maps($|\/)/],
},
Most helpful comment
+1 same issue, when I use ssr mode for nuxt.js i got error on main page:
Unexpected token import (Missing stack frames)
Please anyone help us to solve this problem.
"vue": "^2.5.17",
"nuxt": "^2.3.2",