ray to plane intersection (js)

I have a problem that may be far simpler then I think, but we shall see. Anyway, I’m trying to create a shape “moving” system similar to unity’s. Basically, the user can move and orbit the camera around, and also select shapes. However, I want the user to be able to drag the shapes around, but the shape’s movement should be locked to a plane. In other words, I want to find the intersection point between the ray generated from the cursor out, and the infinite plane which runs on an axis directly through the shape in question. I know this can be done with Plane.raycast, but a)I would have to have an actual plane, and I don’t want it to be user visible and b)Plane.raycast does not return the point of intersection, which is necessary. Ideas? Of course, there might be some solution way simpler then what I am thinking as I am fairly new to Unity.

a) You don’t have to have an actual plane (i.e. a mesh). All you need is a point + normal to define your plane. It is not visible.
b) Plane.raycast returns the distance along the ray where it intersects the plane. From here you can compute the actual point using Ray.GetPoint(d)