Google chart loading message

前端 未结 4 1098
轮回少年
轮回少年 2021-02-09 10:08

I have the following script which works, but has one annoying issue:





        
4条回答
  •  不知归路
    2021-02-09 11:05

    You can also take advantage of Google Chart events to listen for when the chart has loaded and perform an action. It may require you to initially hide the chart container or overlay a loading icon. Example:

    google.visualization.events.addListener(chart, 'ready', function() {
                // Do something like ...
                /* $('#chart_div').css('visibility', 'visible'); // provided this was already hidden
                $('.loading-icon').hide(); // if it exists in your HTML */
            });
    

提交回复
热议问题