Optic neuritis is a condition that affects the eye and your vision. It occurs when the optic nerve is inflamed.