[GH-ISSUE #226] Windows - Failed to load module script #168

Closed
opened 2026-02-25 23:33:36 +03:00 by kerem · 7 comments
Owner

Originally created by @lalitkale on GitHub (Dec 23, 2019).
Original GitHub issue: https://github.com/go-shiori/shiori/issues/226

I am facing issue #182 again. I downloaded the binary "shiori-windows-amd64.exe" for v1.5.0 on Windows 10 and just fired "shiori serve" and getting blank page with
Failed to load module script: The server responded with a non-JavaScript MIME type of "text/plain". Strict MIME type checking is enforced for module scripts per HTML spec error in browser console for 'base.js', 'home.js', 'settings.js' and 'dialog.js'.
go version go1.13.5 windows/amd64

Appreciate any help towards workarounds or proper fix.

Originally posted by @lalitkale in https://github.com/go-shiori/shiori/issues/182#issuecomment-568461097

Originally created by @lalitkale on GitHub (Dec 23, 2019). Original GitHub issue: https://github.com/go-shiori/shiori/issues/226 I am facing issue #182 again. I downloaded the binary "shiori-windows-amd64.exe" for v1.5.0 on Windows 10 and just fired "shiori serve" and getting blank page with `Failed to load module script: The server responded with a non-JavaScript MIME type of "text/plain". Strict MIME type checking is enforced for module scripts per HTML spec` error in browser console for 'base.js', 'home.js', 'settings.js' and 'dialog.js'. go version go1.13.5 windows/amd64 Appreciate any help towards workarounds or proper fix. _Originally posted by @lalitkale in https://github.com/go-shiori/shiori/issues/182#issuecomment-568461097_
kerem 2026-02-25 23:33:36 +03:00
Author
Owner

@deanishe commented on GitHub (Aug 6, 2020):

Can you please post more information? The version of Windows you're using doesn't help much because it's a browser issue.

Please tell me the browser and version you're using, and if possible the request and response headers from its inspector.

<!-- gh-comment-id:670234687 --> @deanishe commented on GitHub (Aug 6, 2020): Can you please post more information? The version of Windows you're using doesn't help much because it's a browser issue. Please tell me the browser and version you're using, and if possible the request and response headers from its inspector.
Author
Owner

@lalitkale commented on GitHub (Aug 9, 2020):

Thank you so much for responding on the issue. I had been using chrome at the time of reporting the issue. Give me a day or two and I will try to reproduce the issue again with new version. If I still get it, will report it. If not, we can close it. Will that work?

<!-- gh-comment-id:671114288 --> @lalitkale commented on GitHub (Aug 9, 2020): Thank you so much for responding on the issue. I had been using chrome at the time of reporting the issue. Give me a day or two and I will try to reproduce the issue again with new version. If I still get it, will report it. If not, we can close it. Will that work?
Author
Owner

@sjbr commented on GitHub (Aug 13, 2020):

I have this problem on Windows 10 using Chrome or Firefox

<!-- gh-comment-id:673241408 --> @sjbr commented on GitHub (Aug 13, 2020): I have this problem on Windows 10 using Chrome or Firefox
Author
Owner

@sjbr commented on GitHub (Aug 13, 2020):

The serve command in windows is not configuring properly the MIME types of js scripts.

image

<!-- gh-comment-id:673242705 --> @sjbr commented on GitHub (Aug 13, 2020): The serve command in windows is not configuring properly the MIME types of js scripts. ![image](https://user-images.githubusercontent.com/864919/90093269-70ba4380-dce8-11ea-90c0-39f10f3cc1f8.png)
Author
Owner

@symgryph commented on GitHub (Aug 13, 2020):

You might want to try the docker image. You’ll need to use the pull request since the one in master doesn’t compile correctly.

<!-- gh-comment-id:673454969 --> @symgryph commented on GitHub (Aug 13, 2020): You might want to try the docker image. You’ll need to use the pull request since the one in master doesn’t compile correctly.
Author
Owner

@lalitkale commented on GitHub (Sep 20, 2020):

It looks like, I am not getting enough time to reproduce the issue again. Hence, we could close the issue.

<!-- gh-comment-id:695813902 --> @lalitkale commented on GitHub (Sep 20, 2020): It looks like, I am not getting enough time to reproduce the issue again. Hence, we could close the issue.
Author
Owner

@70B43r commented on GitHub (Oct 27, 2020):

Stumbled over the same issue.

After some investigation the following hint leads me to the solution:
https://stackoverflow.com/questions/3442607/mime-types-in-the-windows-registry

Changing "ContentType" of Key HKEY_CLASSES_ROOT.js to "application/javascript" solved the problem and go serves not the correct mime.

mimetype.zip

<!-- gh-comment-id:717094034 --> @70B43r commented on GitHub (Oct 27, 2020): Stumbled over the same issue. After some investigation the following hint leads me to the solution: https://stackoverflow.com/questions/3442607/mime-types-in-the-windows-registry Changing "ContentType" of Key HKEY_CLASSES_ROOT\.js to "application/javascript" solved the problem and go serves not the correct mime. [mimetype.zip](https://github.com/go-shiori/shiori/files/5444115/mimetype.zip)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shiori#168
No description provided.