I got a question from a reader:
The answer to all of you: No!
You need to use the concept of Dialogflow REST API middleware
1 The middleware code runs on a server
2 You need to use a server side programming language such as NodeJS
3 You will save the service account JSON file to the server folder where your code is located (or some other folder you can access from the code)
4 You will set up a 'relay' between your JS app and your Dialogflow agent
5 You will communicate with your Dialogflow agent by using the REST API