Why using binary for 'application/javascript' and alike?
See original GitHub issueI don’t understand why you use a binary mime type for
const binaryMimeTypes = [
'application/javascript',
'application/json',
'application/octet-stream',
'application/xml',
'font/eot',
'font/opentype',
'font/otf',
'image/jpeg',
'image/png',
'image/svg+xml',
'text/comma-separated-values',
'text/css',
'text/html',
'text/javascript',
'text/plain',
'text/text',
'text/xml'
];
I think it makes sense for image/*
(because png/jpg are treated as binary format by API Gateway and won’t be displayed without this) but I don’t get why you use it on application/json
or application/javascript
at all, and I don’t know what repercussions this may have on the behaviour of an application.
Could you explain the reason behind this? I would guess something like the following would be enough.
const binaryMimeTypes = [
'application/octet-stream',
'image/jpeg',
'image/png',
'text/comma-separated-values // unsure if that's binary format
];
Thank you!
Issue Analytics
- State:
- Created 6 years ago
- Comments:5
Top Results From Across the Web
Why using binary for 'application/javascript' and alike? #131
I think it makes sense for image/* (because png/jpg are treated as binary format by API Gateway and won't be displayed without this)...
Read more >Using Binary Data with Front-End JavaScript and the Web
A comprehensive write-up on different ways to convert and use binary data in front-end JavaScript code, web browser APIs, and even your ...
Read more >How are efficient data structures like binary search tree ...
In my college, I learned how to define data structures like binary trees and graphs. We were made to write c++ programs that...
Read more >Creating Javascript Binaries For Electron - Jeff Robbins
But if we want to create a software product, Javascript is at a disadvantage because we cannot hide our code. By contrast, compiled...
Read more >Sending and Receiving Binary Data - Web APIs | MDN
Sending typed arrays as binary data You can send JavaScript typed arrays as binary data as well. This is building a 512-byte array...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Agreed. I plan on making that change.
On Fri, Mar 9, 2018, 11:08 PM Vadorequest notifications@github.com wrote:
Added in #136