The FIDE laws of Chess are quite clear about this:
12.3a. During play the players are forbidden to make use of any notes, sources of information or advice, or analyse on another chessboard
So you cannot set up the position on your own board, that would violate this rule.
I am fairly sure that rule applies to FIDE sanctioned over-the-board play and does not apply to chess.com.
The FIDE laws of Chess are quite clear about this:
12.3a. During play the players are forbidden to make use of any notes, sources of information or advice, or analyse on another chessboard
So you cannot set up the position on your own board, that would violate this rule.