This package provides WP GraphQL Stubs for VS Code and Neovim (other IDEs might work as well).
composer require --dev poolshark/wp-graphql-stubs
Alternatively you can download the wp-graphql-stubs.php
and copy it to the root directory of your project folder.
Have fun!