Fork自 DCloud / hello uni-app x
<template> <view> <page-head title="getApp"></page-head>
<button @click="_getApp">getApp</button>
</view> </template> <script> export default { data() { return { checked: false } }, methods: {
_getApp: function () { // const app = getApp() this.checked = true
} } } </script>