If you can write a <script> tag that references app.ab9a9a09fe9.js, presumably you can write a HTTP header that references that same file, no?
How does one tell nginx the names of the files to push if they are generated dynamically? You have to put the names in a separate file and then somehow configure the server using that file?
I have no idea why the original comment by the author is shadow banned.
<link href="{{ "main.css"|asseturl }}" rel="stylesheet" type="text/css" />
Then, your _headers.j2 file should look like this: /*
Link: <{{ "main.css"|asseturl }}>; rel=preload; as=stylesheet
Which will just be replaced with the correct value, same as in your HTML template.