I know that, if I wanted to grep for a pattern only on files with certain extensions, I could do this:
// searches recursively and matches case insensitively in
Yes, for example:
git grep res -- '*.js'