I recommend BlockUI for this scenario.
I'm sure that for a faster computer, the freeze might not happen but to prevent it for other cases, why not have a UI block feature that can either block over the element containing your D3.js table, or simply the entire page (if that's how big your table is)?
That ways the user won't need to see everything freeze until it's rendered, and then you can
$.unblockUI(); to unlock everything.
I would also take a look here for a checklist of things that can speed up the rendering.
Try building the table up in a Document Fragment, and then add the document fragment to the DOM all at once.
var docFrag = document.createDocumentFragment() var table = d3.select(docFrag).append("table").attr("class", "graph-key"), thead = table.append("thead"), tbody = table.append("tbody"); [... the rest of your code should work ...]
Then after you build up your document fragment to have the table just like you want it:
This technique should not lock the UI, since the locking was likely from constantly repainting the DOM for each of your 9000 rows. This will only trigger 1 repaint.
- Rendering d3.js html table without blocking UI
- d3 - rendering an html table on top of an svg element
- Using D3 in React without svg for table rows arn't rendering
- Recursively (or iteratively) make a nested html table with d3.js?
- Drawing an HTML table via D3 doesn't update existing data
- D3 visualization on local machine without HTML server?
- D3.js from HTML table
- Creating SVG elements without rendering them
- Updating an HTML table in d3.js using a reusable chart
- How to get axis ticks out of d3 without rendering in SVG?
- D3.js HTML table from JSON file-- How to create empty values so there aren't missing <td> elements?
- area chart with d3 is not rendering on jsp page but working fine with html
- d3 adding html links to a column of data in a table
- When creating an HTML table with D3, use certain data for a row class rather than cell
- Export d3-generated HTML table as CSV (must work on IE too)
- d3.js — creating HTML table from 2 dimensional array but excluding the first inner array?
- How to create a drop down in a HTML table and d3 bar chart
- Updating a d3.js choropleth / table combo using an html dropdown
- D3.js HTML data table filter by dropdown
- Right-justifying an HTML table created in D3
- Add onmouseover tool-tips to an R html table (based on cells in another data.frame)?
- d3.js nested data update line plot in html table
- change label data of node without rendering graph in D3.js
- Putting HTML Table into ToolTip in D3.js
- d3.js CSV to HTML Table - Header, Average & chart
- Make a specific column bold in an html table
- Static Header and Scrolling html table with d3 from csv
- Heavy calculations and displaying data without blocking UI
More Query from same tag
- D3.js Gauge look like Telerik Radial Gauge
- How do I used D3 to force a user click on a circle object inside of a g.node object?
- d3 - how to show duration interval instead of tickValues
- How to simplify this D3 code?
- Labels issue in D3.js
- How to escape all special characters in a string?
- Uncaught TypeError: d3.arc(...).outerRadius(...).innerRadius(...).text is not a function
- Automating a input slider over time
- NVD3.js Loading line data from JSON
- How to translate SVG and all its children
- d3 flickering Text on setInterval when update data from csv
- How can I add a duration histogram's time data to its bars?
- How to refresh "index" in eventFunction(d,index) for force.links() after splice?
- D3 cannot import json data with custom id specified in the data
- d3.js - Plotting points on zoomable, clickable map
- How to draw data properties aside a graph node?
- Draw curve between two points using diagonal function in d3 js
- D3 area chart not rendering right
- Vue trigger update with custom d3 event
- Simplest D3.js example not working
- Creating a donut chart with dynamic data c3.js
- dc.js How to update yscale after a renderAll
- D3 force layout by node size
- D3 Gradient Fill on Bar Chart - with colour scale
- Wicked_PDF unable to render SVG, canvas or PNG graphics
- d3 select a table row with multiple arguments