Why the onPullDownRefresh set by the WeChat applet is invalid

Because only onPullDownRefreshdoes not work, you need to configure:

  • If it is required for a single page onPullDownRefresh, set it in the json file of the corresponding page "enablePullDownRefresh": true, such as:
{
    
    
  "backgroundTextStyle": "light",
  "navigationBarBackgroundColor": "#fff",
  "navigationBarTitleText": "演示页面",
  "navigationBarTextStyle": "black",
  "enablePullDownRefresh": true
}
  • If you need onPullDownRefreshit for each page "enablePullDownRefresh": true, you can set it for each page , or you can set it in app.json :
{
    
    
	...
	window: {
    
    
		"enablePullDownRefresh": true
	}
}

Guess you like

Origin blog.csdn.net/write_1m_lines/article/details/104168314