FWIW, you're probably seeing issue from not deploying with custom domain and needing to have the stage in the path to access the resource, e.g. https://XXXXX.execute-api.us-east-1.amazonaws.com/production/_next/static/YYYYY/pages/index.js is needed but https://XXXXX.execute-api.us-east-1.amazonaws.com/_next/static/YYYYY/pages/index.js is what the express response actually renders.
FWIW, you're probably seeing issue from not deploying with custom domain and needing to have the stage in the path to access the resource, e.g.
https://XXXXX.execute-api.us-east-1.amazonaws.com/production/_next/static/YYYYY/pages/index.js
is needed buthttps://XXXXX.execute-api.us-east-1.amazonaws.com/_next/static/YYYYY/pages/index.js
is what the express response actually renders.This explains some of issue and attempts to make it work github.com/dougmoscrop/serverless-...
as well as this: github.com/zeit/next.js/issues/6447