How to determine if user is in lightning or classic

In version 10 of Skuid, from JavaScript you can do the following check to determine whether you’re in Lightning Experience:

var inLEX = skuid.platform.get("SFUITheme")==="Theme4d";console.log("Are we in Lightning Experience? " + (inLEX ? "Yes" : "No"));