I'm using nextjs:14.1.0 react:^18 with typescript:5.3.3
and post npm run build command build, I'm getting this document sample -
<!DOCTYPE html>
<html lang="en">
<head>
<meta charSet="utf-8"/>
<meta charSet="utf-8"/>
<link rel="preconnect" href="https://fonts.googleapis.com"/>
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<link rel="stylesheet" href="/_next/static/css/77788e7958239d57.css" crossorigin="" data-precedence="next"/>
<link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-6f58ff0e804dbd64.js" crossorigin=""/>
<script src="/_next/static/chunks/fd9d1056-014bdae05f6da747.js" async="" crossorigin=""></script>
<script src="/_next/static/chunks/69-855792fd7a371558.js" async="" crossorigin=""></script>
<script src="/_next/static/chunks/main-app-38e544f4272c039c.js" async="" crossorigin=""></script>
<script src="/_next/static/chunks/899-4ea934008c86dde4.js" async=""></script>
<script src="/_next/static/chunks/370-81c677ced3d8668d.js" async=""></script>
<script src="/_next/static/chunks/198-c1847edf924a8a70.js" async=""></script>
<script src="/_next/static/chunks/244-7d607b06b949a266.js" async=""></script>
<script src="/_next/static/chunks/107-3ee303d218f91d93.js" async=""></script>
<script src="/_next/static/chunks/964-fe494fec62b2f455.js" async=""></script>
In localhost, its working fine, but in server it's been failing with following error-
Refused to execute script from 'https://abc.domain/_next/static/chunks/webpack-6f58ff0e804dbd64.js' because its MIME type ('') is not executable, and strict MIME type checking is enabled.
and others tags are also failing where attribute crossorigin is available, Hence I'm not using SSR, but just relied on static build pages.
Also, how could I attached <script type="text/javascript" src="./webpack-6f58ff0e804dbd64.js" crossorigin="" />
as I'm using Next.js latest recent version, is there any config available to do above required stuffs.