by Ricardo “Rudxain” Fernández Serrata
Version 11 (December 21, 2022)
Download (150 downloads)
An extended and updated version of mimeType function. It returns an array of media types corresponding to the input text.
To do so, it creates a dictionary that maps extensions to their corresponding types, by downloading CSV files from the official IANA registry. Once the dictionary is cached by Atomic Store, the flow returns output faster and more reliably since it avoids internet use.
If you found a file-extension that shouldn't map to "application/octet-stream", please let me know.
Some variables are shared across several blocks to reduce memory usage and block-count.
I've optimized it as much as possible, which means there are some unnecessary blocks.
This is not intended to be directly used by a human, it should be used by a flow for automatic MIME recognition
5 stars | 0 | |
4 stars | 1 | |
3 stars | 0 | |
2 stars | 0 | |
1 star | 0 | |
Reports | 0 |
Rate and review within the app in the Community section.