isValidComponent() doesn't really care what TypeScript might think its argument is.