Yeh, but not if it was a result of an early war and you vassalized him without being able to see oil, uranium, etc yet.
That's exactly my point. Oil and uranium are revealed by different techs than enable them. If you reveal them and it turns out that your vassal has them and you don't, that's when gifting them the tech becomes an option. Usually a civ has to be in pretty bad shape before they'll capitulate and won't be able to tech as well as you. As I mentioned already, it's a risk, but sometimes it's worth it.