Questions tagged [nuxtjs2]

Questions related to Nuxt v2 only. Concerned repo: https://github.com/nuxt/nuxt.js

Questions related to Nuxt v2 only. Concerned repo: https://github.com/nuxt/nuxt.js

39 questions
3
votes
0 answers

NuxtJS PWA breaks site /_nuxt/ file loading

On my NuxtJS v2 site I enabled the PWA, sometimes when I load my site, the whole site becomes broken, especially all images do not load in anymore. Looking at the console & network tab, I can see it's getting a 404 on /_nuxt/ javascript files. I do…
Finn
  • 127
  • 1
  • 1
  • 12
3
votes
3 answers

How to configure production URL for Firebase callable function in nuxt app?

I have a nuxt app uploaded to Firebase (served as cloud function). I have also a callable function that I'm trying to call from the app. The problem is that it tries to call localhost url instead of the production one. My Firebase setup in…
Eggon
  • 2,032
  • 2
  • 19
  • 38
2
votes
1 answer

NuxtJS nested routes with param

https://dev.site.io/websites/1bbe6526-61c1-4077-8400-77a642580eac/apps/30620171-af2f-4e82-854e-2bb797c017d8 what would the folder structure look like to access both website and app id…
Charlotte Wells
  • 375
  • 1
  • 2
  • 8
2
votes
0 answers

Error while injecting javascript class as a plugin in nuxtjs2

I am trying to inject a javascript class as a plugin. I get following error: Cannot read property 'log' of undefined Class to be injected: // helper/logging.service.js export class LoggingService { constructor (prefix) { this.prefix =…
mahatmanich
  • 10,791
  • 5
  • 63
  • 82
2
votes
2 answers

nuxtjs toggle individual items generated by v-for loop

I want to create a simple accordion like structure but somehow I can't manage to toggle individual elements:
mahatmanich
  • 10,791
  • 5
  • 63
  • 82
1
vote
1 answer

The geography display on the leaflet map does not appear in nuxtjs version 2

Package installed: leaflet: ^1.9.4 nuxt: ^2.0.0 node: 14.21.3` npm: 6.14.18 The problem: The geography display on the leaflet map does not appear, I used GeoJSON. I have written the initials of the leaflet correctly along with the CSS style link in…
rahman022
  • 23
  • 4
1
vote
1 answer

Dynamically adding a prefix to a named route in vue 2 / nuxt 2

Pretty simple question, I am pushing a named route like so: this.$nuxt.$router.push({ name: "my-named-route-id-foo", params: { id: this.$route.params.id } }); But I want to conditionally add a prefix to this so instead of the resulting URL always…
JeremyW
  • 241
  • 1
  • 2
  • 9
1
vote
0 answers

Nuxtjs2 iPhone keyboard is not shown on PWA

I have run into a problems with iPhone default keyboard while using NuxtJS. It happened when I installed 2 PWA apps to homescreen. The keyboard was missing (refer my screenshot for example). Steps to reproduce problems Installing 2 PWA apps (save…
tú anh
  • 11
  • 3
1
vote
2 answers

Receiving CORS policy error on every API request nuxtJS

Im trying to run a Laravel V8.14(Backend) and nuxtJS 2.15(Frontend) app but unfortunately every API request (including SSR ones) are getting CORS policy error on my LOCAL computer using WAMP Running npm run dev everything gets compiled and it starts…
Pc Monk
  • 75
  • 2
  • 4
  • 24
1
vote
1 answer

Nuxt plugin cannot access Vue's 'this' instance in function blocks

So I have managed to inject hls.js to work with nuxtjs $root element and this I did so doing it like this (hls.client.js): import Hls from 'hls.js'; export default (context, inject) => { inject('myhls', Hls) } and nuxt.config.js plugins: [ …
mahatmanich
  • 10,791
  • 5
  • 63
  • 82
1
vote
1 answer

How do I programmatically bind in video player URLs in Nuxt/Vue?

I was looking for an idea of how to programmatically bind in video player urls. I understand the idea of using img and doing v-for and a :src, but the url for my videos get put in the data of the script. Is it possible to bind and make these…
0
votes
0 answers

Run head script on server side nuxt js

I'm trying to add meta script tag to nuxt page inside head tag head() { return { title: 'Test', script: [ { vmid: 'meta1', innerHTML: `console.log('test') `, type: 'text/javascript', body: true, }, } } If…
Tharindu Prabodhana
  • 181
  • 1
  • 4
  • 16
0
votes
0 answers

Deployment SPA and Static pages to hosting error 404 page not found

After building the app (npm run build ), I copy dist/ folder content to my hosting in my source web /pages/project/_coin_id/index.vue When access on localhost:3000/project/ethereum is ok But when access on live hosting, domain.com/project/ethereum…
Hai Truong IT
  • 4,126
  • 13
  • 55
  • 102
0
votes
0 answers

State only resetted partially

Using Vuex on a Nuxt2 application. A CRUD of categories has an index, a create and an update views. Every time the user enters the update or create view, an action is dispatched which is supposed to reset the state to its default values. However,…
fombo
  • 103
  • 1
  • 7
0
votes
0 answers

How can i have access vuex store in a nuxt 3 server middleware?

im currently working on integration a nuxt2 project into nuxt3 and in the nuxt2 project i had a middleware/single-use-token.ts file which contains something like this export default function (context: any): void { const { stuffFromServer1,…
Pietsen
  • 1
  • 1
1
2 3