angular.js - How is the will appear event of the page implemented in angular?
黄舟
黄舟 2017-05-15 16:53:21
0
1
518

I want to execute a method (such as refreshing the page data) every time page A is about to be displayed. How should I implement this?
PS: The function in the controller is only called when the page is created. It will not be called when returning to this page again?

黄舟
黄舟

人生最曼妙的风景,竟是内心的淡定与从容!

reply all(1)
習慣沉默

You can use the resolve option of routing to solve the operation you want to perform, and the returned data can be injected into the controller.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template