<script src="...-.txt" type="text/javascript"> not a valid JavaScript MIME type

Hi, hope fully this is corret forum for this question:
I’m trying to deliver a .txt file with a webpage and access it therein as a javascript element This works fine - but firefox reports:
The script from “http://localhost:,…-.txt” was loaded even though its MIME type (“text/plain”) is not a valid JavaScript MIME type.
Trying to balance user requirements/bundler etc - so .txt file is really my prefered option, but without using ajax later to request.
Can anyone advise - is this going to remain reliable in the mid-term or likely to break sometime soon!?
Many thanks