There are two types of Visualforce page requests:
- A get request is an initial request for a page either made when a user enters an URL or when a link or button is clicked that takes the user to a new page.
- A postback request is made when user interaction requires a page update, such as when a user clicks on a Save button and triggers a save action.
Using an actionFunction with rerender attribute will cause a postback request to the controller, thus the Visualforce Viewstate will need to go back to the controller and de-serialize so that the instance of the controller is validated against the page state.
If your actionFunction is rerendering something that is a very large static and is not transient, you should rethink your controller design a bit. If there are instance members that are not being actively accessed on your page, but just used or rendered conditionally, you can make them transient. This would reduce your viewstate payload considerably. Try not to throw List<>, Array, or Map<> collections at your page unless you have to.
One of the major reason of loading an entire page is using
<apex:form> covering the entire page. You may be using a single
<apex:form> for all action functions, command button or command link.
viewstate is related to
<apex:form> if your form reloads then
viewstate will be reload with it.
Try to use multiple
<apex:form> for larger pages and exclude all unwanted information which should not be in between
<apex:form> tag. All information between from is part of view state.