I was looking for an easy way to access an IMU for some quick tests. I settled on a smartphone sensor because all the sensor fusion / calibration software is built in. Furthermore, the device motion and device orientation events available in the Web API make it easy to grab the data, send it to a computer through websockets and then pipe it into any application.
These numbers are all in degrees. A sample is available on this site or on codepen. It may take a bit of time for the orientation to calibrate itself.
Additionally, there is also the device motion event, which can get the accelerometer and gyroscope data.
Rotation rate might not be useful for orientation given the orientation data already available, but acceleration can filtered and then used for positioning.