Gets an index of a global plugin based on the given key.
The unique plugin key.
The index of the plugin within the plugins array.