search

Home  >  Q&A  >  body text

javascript - How to bind the data obtained by Vue2.0 using axios? Binding failed/(ㄒoㄒ)/ error reported

is a local json file. I was able to get the request with great difficulty, but I couldn’t bind the data. It took a day just to do this. /(ㄒoㄒ)/~~ Or where can I find more details about using axios with Vue? Can you share the document so I can take a look? I looked it up on the official website and found it. Baidu has been fragmented for a long time and it’s hard for novices to understand. . .

The picture is the HTML and script part

vue.runtime.esm.js?a427:554 [Vue warn]: Property or method "footers" is not defined on the instance but referenced during render. Make sure to declare reactive data properties in the data option. 
(found in <Vfooter> at E:\vue\egghead-nuxt\components\footer\vfooter.vue)

This is an error message, saying that my footers are undefined. footers is one of the json data

phpcn_u1582phpcn_u15822806 days ago599

reply all(5)I'll reply

  • 给我你的怀抱

    给我你的怀抱2017-05-19 10:40:02

    Bind data

    I updated it below and marked it in the picture. Take a look

    reply
    0
  • 给我你的怀抱

    给我你的怀抱2017-05-19 10:40:02

    You don’t have data binding like this.

    reply
    0
  • PHP中文网

    PHP中文网2017-05-19 10:40:02

    export default {
        data() {
            return {
                footers: []
            }
        }
    }

    reply
    0
  • PHP中文网

    PHP中文网2017-05-19 10:40:02

    footers are not defined and the obtained data is not bound

    reply
    0
  • 黄舟

    黄舟2017-05-19 10:40:02

    created may not be executed, it may require this.$nextTick

    reply
    0
  • Cancelreply