-
Where does the code in nuxt.js that does not need to be executed on the server be executed?
I want to load the data on the first screen on the server, that is, there is still part of the return data, hidden in asyncData, and I want to render it on the client. How do I write this? ...
-
How to use store and server api in axios secondary encapsulation of Nuxt
the project uses token to authenticate users. I wrote in NuxtServerInit that the token stored in the Session of Node is written to Store, that is, after the user logs in, there are three places to store Session, Store and local localStorage, in the toke...
-
Js if the plus sign or minus sign in the string is all replaced by a comma
var replaceStr = - ;
var str = a.value;
_this.$set(a, newyasi , str.replace(new RegExp(replaceStr, gm ), , ));
-sharp-sharp
a.value~...
-
How to prevent vue from displaying the error bounce box returned by the background
such an error pop-up box pops up directly after requesting the interface. Can you cancel the error report that popped up automatically? This display on the interface is also not conducive to the user experience.
...
-
Nuxt reported an error 'disabled' of null' on the test server
dom
<el-form-item label=":" :label-width="formLabelWidth" prop="email">
<el-input :disabled="emailDis" v-model="sideForm.email" auto-complete="off" placeholder="&...
-
The use of vuex state tree
export const state = () => ({
wishNum: 0
});
export const mutations = {
SET_WISH: (state) => {
state.wishNum = 0;
},
}
let Num = res.total;
setStore("wishNum", Num);
-sharp-sharp whether I am writing this correctly. I ...
-
How does nuxt.js add js to the page header to determine the ie version, and then display a prompt when it is lower than a certain version?
at first I thought of adding js, directly to the index.html header, but I couldn t find it. I didn t seem to find it. Then I thought of head tag management that comes with nuxt, but it won t work if ie doesn t support it. ...
-
The asyncData parameter in nuxt in nuxt, and the problem that the value of context store is empty after the page is refreshed.
functional requirements: there is a search box on the home page and a search box on the list page. Enter the search content on the home page and jump to the search page to perform the search .
nuxt implementation: save the searchKeyWords field into v...
-
Nuxt does not respond or report errors when he wants to add his own plugins.
problem description
add a test.js, to the plugins directory as shown on the official website. I just want to hang an encapsulated websocket instance to the Vue.prototype component for direct use. Nuxt.config.js is also configured according to the docu...
-
How do I get the token, in the plugins/axios.js file and assign it to the http request header in the nuxt project?
nuxtplugins axios.jstokenhttp...
-
After nuxt packages the SPA mode, the first visit to the website will show a blank screen (wait for all the data to come back before the page is displayed)
the explanation given on the official website is: "When running Nuxt.js in SPA mode, there is no content from the server side on the first page load. " So, instead of showing a blank page while the page loads, we may show a spinner.
This property can...
-
Error report after nuxt running
was right before. After pulling the file from git again, npm install and son npm run dev reported this error. I don t know what s going on. ...
-
Nuxt project page refresh error?
vendor.5b74c6bf3483097bb00d.js:2 [nuxt] Error while initializing app
DOMException: Failed to execute appendChild on Node : This node type
does not support this method.
at Object.appendChild
The page has no problem running locally, but refr...
-
How does iview support SSR and Nuxt.js?
I looked through iview s changelog and commit records to figure out how iview solved the SSR problem, but I couldn t find the relevant code (maybe I didn t translate it in detail enough), so I d like to ask developers who are familiar with iview, iv...
-
How nuxt, uses vuex in * .js
problem description
the environmental background of the problems and what methods you have tried
related codes
Please paste the code text below (do not replace the code with pictures)
what result do you expect? What is the error message actu...
-
Nuxt reported an error type check failed forprop "news" Expected Array
error type check failed for prop "news " when using Nuxt.js. Expected Array, got Function. Found in . but there is no problem with re-npm run dev, but this error is reported every time the browser is changed a little. But the terminal is normal.
<...
-
Every time there is a change in the use of asyncData, in the nuxt framework, it needs to be re-npm run dev to display properly.
the nuxt framework uses asyncData, and needs to be re-npm run dev every time it changes. Otherwise, the error will be reported, and the code and error will be as follows
asyncData({ params }) {
let getNews = axios.getNews({ limit: 2 })
let ge...
-
How does nuxt reference namespaces
how does the unxt framework add XML namespaces to the interface? For example: < html xmlns:wb= " http: open.weibo.com wb "> how to add namespaces dynamically? I don t think there s any description in the document. Thank you for the emergency ...
-
How does nuxt dynamically add xml namespaces to html tags
nuxt templates are automatically compiled and generated and cannot be added directly. How to dynamically add xml namespaces to html tags. For example: add < html xmlns:wb= " http: weibo.com "> or how to add it directly using js. ...
-
Unxt quotes Weibo component to report an error
the component can be displayed normally by referencing this interface at first, then the error shown in the figure above is reported after requesting Weibo interface: < wb:like appkey= "111 " type= " simple "style= " display: inline-block;padding-t...