I'm in the process of breaking down a theme to a bunch of plugins, I wanna do it one by one so hell won't break loose.
Question is, Suppose I have a plugin which depends on a class from the theme, where and how should I validate his existence and load it, and if not exist how do I properly show an error and avoid loading the plugin, is it on the activation hook? I'm pretty new to plugins, and would love to get best practices, or any good docs references regarding my issue, thanks!
I don't need to check another plugins existence, just another code that is currently part of the theme.