Gyroscopes are used in spaceflight as parts of inertial systems to monitor spacecraft attitude. They are not absolute, they will drift slowly over time and so need occasional calibration via other measurements such as those provided by star cameras. During launch or other high-thrust and vibration, daytime, and other short duration maneuvers they are indispensable.
Traditionally gyroscopes were based on physically spinning objects, but MEMS-based gyroscopes are used in some applications (perhaps in gyrocompasses as discussed in What is a gyrocompass and how might one be used by a planetary rover?), and ring laser and optical fiber-based gyroscopes offer extremely high performance, lower weight and no moving parts.
Question: These days are new gyroscopes used in spaceflight for precision applications pretty much all optical, or are mechanical gyroscopes still selected in some cases?
note: I'm only asking about gyroscopes used in attitude determination, and not reaction wheels used for attitude control. The distinction is outlined nicely in @OrganicMarble's answer.