Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UTF-8 support #188

Open
mattgodbolt opened this issue Jul 14, 2023 · 0 comments
Open

UTF-8 support #188

mattgodbolt opened this issue Jul 14, 2023 · 0 comments
Labels

Comments

@mattgodbolt
Copy link
Owner

Minified javascript files love to use UTF8 in the source,

e.g. a minified version of:

                const latin_convert = {
                    'æ': 'ae',
                    'â±¥': 'a',
                    'ø': 'o',
                    'â„': '/',
                    '∕': '/'
                };

will drop the single-quotes and store the keys as pure æ....which requires the javascript is served as utf-8.

The current type we server "text/javascript" means users get encoding or parse errors. Maybe application/javascript will fix, but other servers will serve it with application/javascript; charset=utf-8 so maybe we need to do proper charset stuff to have this work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant