cal-heatmap icon indicating copy to clipboard operation
cal-heatmap copied to clipboard

nodejs?

Open hampsterx opened this issue 9 years ago • 4 comments

is there anything stopping this from working on the server side? Haven't tried yet :)

hampsterx avatar Mar 08 '15 19:03 hampsterx

How will you use it on NodeJS ?

The graph is only useful when rendered inside a webpage.

wa0x6e avatar Mar 08 '15 19:03 wa0x6e

a couple of cases for server side rendering to svg/png

  • inclusion in reports (pdf)
  • inclusion in other online documentation (markdown readme file is my use case)

Happy to have an initial hack if you can suggest a starting vector

hampsterx avatar Mar 10 '15 19:03 hampsterx

I'm afraid I'm not familiar enough with nodejs to help you with this.

wa0x6e avatar Mar 10 '15 20:03 wa0x6e

@hampsterx the major problem is that the heatmap need a selector (an actual element) to be inserted. It might work if you use jsdom to create a virtual DOM in the server. This guide might help.

vnen avatar Mar 13 '15 00:03 vnen

Should works fine since v4, as all jest tests are now using JSDOM and node

wa0x6e avatar Dec 16 '22 16:12 wa0x6e