Thank you for writing this great library! It has been very easy to work with outside of this one issue.
After a child is reloaded, any methods that it calls on the parent are executed on the parent side multiple times. The child only receives one response, but the parent executes the method an additional time for every time the child is reloaded.
For example, if the child is reloaded three times, and then calls a parent method once, the parent will execute that method 4 times, and return only the first result to the child.
This is easy to reproduce by placing a console.log statement inside the 'add' method in the usage example, and right clicking inside the child pane and clicking 'reload frame'.
This is a fairly significant problem if the parent method has any side effects. I have not had a chance to look into the cause yet.
Thank you for writing this great library! It has been very easy to work with outside of this one issue.
After a child is reloaded, any methods that it calls on the parent are executed on the parent side multiple times. The child only receives one response, but the parent executes the method an additional time for every time the child is reloaded.
For example, if the child is reloaded three times, and then calls a parent method once, the parent will execute that method 4 times, and return only the first result to the child.
This is easy to reproduce by placing a console.log statement inside the 'add' method in the usage example, and right clicking inside the child pane and clicking 'reload frame'.
This is a fairly significant problem if the parent method has any side effects. I have not had a chance to look into the cause yet.