Home forums Chart Support Styling Charts in React

Tagged: , ,

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #27853

    Hello, how do you style charts in React?

    I have attempted to do so by referencing their class names in my .css file, as well as by passing them in inside my options object, but neither method works.

    If you could let me know how I could pass style values for properties like “backgroundColor”, “position”, “display”, in CanvasJS’s React integration (as props, hopefully), that’d be great! — Thanks!

    #27861

    @mepc36,

    You can style the chart container by passing the style attributes as containerProps as shown in this example.


    Shashi Ranjan
    Team CanvasJS

    #27973

    Awesome, thank you Shashi!

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.