How to transform a cframe to cframe.angles

ok so we have a cframe
for ex:
CFrame.new(raycast.Position)
how do I transform that to cframe angles, like CFrame.Angles(math.rad(10), 0, 0) or smth
I heard there’s like :ToEulerAxisXYZ or smth but I have no idea how to use it so please tell me what to use and how to use it
ok thx

Are asking how to rotate a cframe by a certain angle? Or to extract just the orientation x y and z?

yes i meant how to extract;;;;;;;;;;;;;;

You can use CFrame:ToOrientation to get the x, y and z rotations in radians

local X, Y, Z = RandomCF:ToOrientation()
--Convert the radians to degrees (if you need it)
X = math.deg(X)
Y = math.deg(Y)
Z = math.deg(Z)