I think a description of why canvas was used would be nice in the README. My (probably naive) view is that browsers are pretty good at table-ish layouts so it’d be great to know why canvas was chosen.
Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
41–50 of 108 posts
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#42Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#43I think a description of why canvas was used would be nice in the README. My (probably naive) view is that browsers are pretty good at table-ish layouts so it’d be great to know why canvas was chosen.
1 canvas performance is higher than dom rendering 2 easy to write code github.com/xspreadsheet used table
In general, unless you are doing something very simple, replicating the dom and css engine with canvas is an uphill battle.
That being said, I love that the xterm terminal uses a canvas renderer and now going to move to a webgl renderer. Terminal like UI with monospaced fonts are an excellent candidate for low level rendering.
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#44This is amazing and fast. I'm complaining about it actually being easily broken only because I really wished this worked well, so I could build on it. It crashed for me on literally the very first thing I tried. I opened up the demo page, typed in 4 numbers in a column (in positions a5,a6,a7,a8), then typed "=sum(a5:a8)" in position a9, hit enter, and the demo crashed (with canvas all messed up). There's a traceback…
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#45This is amazing and fast. I'm complaining about it actually being easily broken only because I really wished this worked well, so I could build on it. It crashed for me on literally the very first thing I tried. I opened up the demo page, typed in 4 numbers in a column (in positions a5,a6,a7,a8), then typed "=sum(a5:a8)" in position a9, hit enter, and the demo crashed (with canvas all messed up). There's a traceback…
It looks like it's case sensitive. Worked for me with "=SUM(A5:A8)"
to anyone else wondering: you can browse the available function with the button to the right. ( SUM, AVERAGE, MIN, MAX and CONCAT )
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#46AFAIK (and in evidence in this case) you can't use the normal "find in page" (control-f) when using canvas. Consistency in functions like find is one of the greatest things about the browser, this approach removes it. Probably (!) an implementation will add its own find, which may be better or worse, but as browsers are best thought of as universal information vehicles, it won't automatically fit into accessibility a…
Generally I agree, however even some DOM-based implementations of spreadsheets (and similar applications with very long lists of things) break "find in page" due to them only rendering visible cells for performance reasons. For example, Google Sheets hijacks command/control-F to show their own search for this reason.
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#47Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#48> "dependencies": {}
:)
Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#49Re: Show HN: X-spreadsheet – A JavaScript canvas spreadsheet for web
#50I think a description of why canvas was used would be nice in the README. My (probably naive) view is that browsers are pretty good at table-ish layouts so it’d be great to know why canvas was chosen.
If by table-ish layouts you mean using the element to render something like this then browsers might be OK at it but the woefully inadequate to do anything more than the most basic table renderings. Virtual scrolling or frozen rows/columns is a lot of manual work to do on top of a .