We present JWST/NIRSpec high-resolution G395H/F290LP spectroscopy of MACS0647−JD, a gravitationally lensed galaxy merger at z = 10.167. The new spectroscopy, which is acquired for the two lensed images (JD1 and JD2), detects and resolves emission lines in the rest-frame ultraviolet and blue optical, including the resolved [O ii] λ λ3726, 3729 doublet, [Ne iii] λ3870, He i λ3890, Hδ, Hγ, and [O iii] λ4363. This is the first observation of the resolved [O ii] λ λ3726, 3729 doublet for a galaxy at z > 8. We measure a line flux ratio [O ii] λ3729/λ3726 = 0.9 ± 0.3, which corresponds to an estimated electron density of log(ne/cm−3)=2.9±0.5 . This is significantly higher than the electron densities of local galaxies reported in the literature. We compile measurements from the literature and further analyze the redshift evolution of n e . We find that the redshift evolution follows the power-law form of n e = A × (1 + z) p with A=54−23+31 cm−3 and p=1.2−0.4+0.4 . This power-law form may be explained by a combination of metallicity and morphological evolution of galaxies, which become, on average, more metal poor and more compact with increasing redshift.