Mautic, NGINX and JS browser cache headers

Your software
My Mautic version is: 4.2
My PHP version is: 7.4
My Database type and version is: Mysql 8

Your problem
My problem is: I want to add cache headers to the response for /forms/form.js requests. But my settings dont seem to work.

These errors are showing in the log:

Steps I have tried to fix the problem:

Tried adding expires directive to multiple blocks within the nginx config. Havent really gotten anywhere with it.

Latest attempt was:

location ~ (.*).js {
try_files $uri /index.php?$args;
expires 15d;

Im not sure if perhaps its the query string throwing it off at this point? Although I think the above block accounts for that, stating that ALL matches to this rule get an expires header of 15d…

Any help is appreciated.