Configuring JS Engine and Metabind

What I’m trying to do

I am trying to setup a button using metabind that triggers a javascript file. The button will be part of a template that I use for new clients.

This is well outside my experience (the javascript part) so it’s hard to trouble shoot.

Things I have tried

1.Javascript file is saved as extractDataAndUpdateFrontMatter.js in EXTRAS/Scripts folder

  1. Metabind button is setup as follows
label: Update Data
icon: ""
hidden: false
class: ""
tooltip: ""
id: ""
style: default
  - type: js
    file: extractDataAndUpdateFrontMatter.js
    args: {}

  1. Button is included in a new client template, which I use to setup a new note.

  2. Script file folder location is set to EXTRAS/Scripts in Templater settings.

  3. When I use the template to set up a new note, then click on the button, I get error in console “File is not found”.

So, there’s a step where I need to instruct JS engine or metabind to look for scripts in a particular place, but I can’t see that in the settings for either plugin.

  1. I have tried to find solutions in forums and online, but the level of understanding is higher than I have.

For example, “add folder to XYZ” doesn’t include the "open the settings menu, click on the plugin in the community plugins menu, go to the second screen entitled “ABC” and add the folder to the field labeled “whatever the label is”.

I would very much appreciate someone pointing me to the very obvious step I have missed!