Make recordwidget js functions accessible after onload event