We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
框架需要给出最佳实践或者方案,两种情况:
一个简单的做法是封装一个 utils/pageSetup.js,每个页面自己调用下:
// src/pages/Home/index.js import setupPage from '@/utils/setupPage'; setupPage('home', { //...options }); export default function() { return <>Home</>; }
但感觉不是一个优雅的方案。
比如权限、埋点、监控打点等,理论上用 hooks 就可以,但是我们现在缺少这方面的规范。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
框架需要给出最佳实践或者方案,两种情况:
1. 页面级 setupAppear 之类的逻辑
一个简单的做法是封装一个 utils/pageSetup.js,每个页面自己调用下:
但感觉不是一个优雅的方案。
2. 组件声明周期的定制
比如权限、埋点、监控打点等,理论上用 hooks 就可以,但是我们现在缺少这方面的规范。
The text was updated successfully, but these errors were encountered: