MoralCode / AdvancementURLFiller

A small utility webpage for assembling giving URLS for RIT Advancement
https://moralcode.github.io/AdvancementURLFiller/
MIT License
0 stars 0 forks source link

Note on Nginx #5

Open ct-martin opened 14 hours ago

ct-martin commented 14 hours ago

It may be worth adding a note like the following to address Nginx's decision not to follow RFC 4329, which enables serving .mjs files with the correct MIME type so browsers interpret it as JavaScript.


Using Nginx

If you're using Nginx to serve the files, you may need to change your MIME types to serve JavaScript module files correctly.

In the mime.types file (typically found at /etc/nginx/mime.types), the line with:

application/javascript js;

should be changed to:

text/javascript js mjs;

For reference, the upstream issue can be found here: https://trac.nginx.org/nginx/ticket/2216

MoralCode commented 14 hours ago

sounds good! Since the site is curreently hosted on GH pages (no impact to the prod site), and is so new/probably low use i'll probably just leave this issue open as an FYI for future users. Happy to merge a PR to update the README though!

That said, thanks for the contribution!