How can I make a game object look at another one in 2D without using a rigidbody?

I already have a method, hor¡wever, it uses a rigidbody, and I don’t want to put any rigidbody in this gameobject, any solutions?

Just found it:

    Vector2 mp = cam.ScreenToWorldPoint(Input.mousePosition);
    float xDiff = mp.x - transform.position.x;
    float yDiff = mp.y - transform.position.y;
    float angle = Mathf.Atan2(yDiff, xDiff) * Mathf.Rad2Deg + 130;
    transform.rotation = Quaternion.Euler(0,0,angle);

(mp is the position I want it to poit)