If you look into the next.js doc you'll see:

since I want to use this buildId to make a predefined service worker file(not using runtime caching), I wonder why buildId for app.js differs from other js files. you can see screenshot of this behaviour in my project:

I think buildId should be a constant value between all files.
buildId for app.js is different from all other next.js generated js files.
I'm in the same spot. Working on a service-worker to cache the app and make it a PWA using workbox through next-offline and it seems impossible to cache app.js.
@iamsoorena have you found any workaround for this?
I'm thinking about switching from next-offline to sw-precache-webpack-plugin.
This issue seems to be a bit old now (5 months), any support would be much appreciated.
This has been changed in 5.1, the buildId is now used for app.js too.
Most helpful comment
This has been changed in 5.1, the buildId is now used for app.js too.