Node.js/nuxt/asyncData:修订间差异
来自康健生活
| 第1行: | 第1行: | ||
== 引用 == | == 引用 == | ||
asyncData 参数只在页面组件中有效。 | asyncData 参数只在页面组件中有效。 | ||
== data == | |||
在 asyncData 中获取数据,return 的数据,nuxt 会自动混入到 data 中。 | |||
== this == | == this == | ||
在页面组件中 this 的值为 undefined | 在页面组件中 this 的值为 undefined | ||
| 第1行: | 第1行: | ||
== 引用 == | == 引用 == | ||
asyncData 参数只在页面组件中有效。 | asyncData 参数只在页面组件中有效。 | ||
== data == | |||
在 asyncData 中获取数据,return 的数据,nuxt 会自动混入到 data 中。 | |||
== this == | == this == | ||
在页面组件中 this 的值为 undefined | 在页面组件中 this 的值为 undefined | ||