website-v2
website-v2 copied to clipboard
how can i use local json
async asyncData ({ params }) {
let { data } = await axios.get('~static/test.json')
return data
}
errmsg: (node:4796) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 2): Error: connect ECONNREFUSED 127.0.0.1:80
@xiao8cn Did you end up figuring this one out?
I have the exact same problem with local json files. How was this problem solved?