Trace visibility depending from checkboxe


I wounder, if there any way to make dependency betwen checkboxes states and traces visibility. I mean: i have a plot on my html page with some traces on it (10 for example). Also there are 10 checkboxes on the same html page. And I want to make visibility control of traces with this checkboxes. Now I use plotly_update function to make changes in traces visibility. And i want to make direct dependence betwen checkbox state and trace visibility, something like that:
trace[i].visible: checkbox[i].ischecked