Actions
Task #104815
openSupport ECMAScript module file endings
Start date:
2024-09-04
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
13
PHP Version:
Tags:
Complexity:
Sprint Focus:
Description
Problem/Description¶
It's quit common to use file ending mjs
in the node-js universe in productive environments. There is no need to add them into DDEV's .htaccess, but on at least 2 checked known TYPO3 hoster companies, mjs
isn't delivered with mime-type application/javascript
(like js
is).
My scenario where I had troubles¶
The reason for this issue was that I'm using datatables package in a TYPO3 backend module datatables.net-bs5
. In the DDEV env all is working well. After deploying to production – in my case Mittwald (hey, I'm not bad-mouthing the host!) – a mime-type error occurs. First I thought that CSP could be problematic. After a quick research I came with the conclusion that this is a quite common file ending which should be added to core's root-htaccess.
ToDo(s)¶
- Add simple support for mjs via htaccess o-o-t-b in the TYPO3 core.
Acceptance Criteria¶
- mjs file response contains an
application/javascript
mime-type
Actions