Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/adobe/react-spectrum
/ radToDeg
Function
radToDeg
packages/react-stately/src/color/useColorWheelState.ts:98–100 ·
view source on GitHub ↗
(rad: number)
Source
from the content-addressed store, hash-verified
96
}
97
98
function
radToDeg(rad: number) {
99
return
(rad * 180) / Math.PI;
100
}
101
102
// 0deg = 3 o'clock. increases clockwise
103
function
angleToCartesian(angle: number, radius: number): {x: number; y: number} {
Callers
1
cartesianToAngle
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected