
I also have the same question about accessing controller variables when using JavaScript remoting in a Visualforce page. I understand the problem with submitting the entire form every time a controller method is called, especially when the application needs to respond quickly and network latency is already an issue. JavaScript remoting seems like a useful way to reduce unnecessary form submissions, but having to return previously stored values to the JavaScript callback and then pass them back into another remote action can make the implementation more complicated. This becomes even more challenging when the controller maintains complex data structures such as maps containing wrapper classes, lists, and sObject records that need to remain available across multiple operations.
Has anyone found a cleaner approach to maintaining or accessing this controller-side state while using JavaScript remoting? I am particularly interested in whether there is a recommended pattern that avoids repeatedly transferring large amounts of data between Apex and JavaScript while still keeping the application responsive. It would also be helpful to understand the limitations of JavaScript remoting in this situation and whether a different approach would work better for preserving complex objects between calls. In a similar way, tools such as Gamepad Tester Free can help users check controller inputs directly without unnecessary complexity. If someone has handled a similar scenario in a Salesforce1 application, I would appreciate hearing how you managed the controller variables without increasing network traffic unnecessarily. Perfectly stated here as well gamepadtesterfree.com