'Add Button to Modebar to display in Fullscreen (Plotly JS)

I would like to add a custom button to the plotly graph to make the graph full screen. I have seen some solutions for the programming language 'R' but I did not seen any for JS.

Would be happy if somebody could help me.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source