istextorbinary
istextorbinary copied to clipboard
Determine if a filename and/or buffer is text or binary. Smarter detection than the other solutions.
Hi there, I'm working in a browser-only context and would like to see if an uploaded file is a text file or not. It seems though that the Buffer argument...
Any plans to fully support cloudflare workers (or serverless in general)? [this](https://github.com/bevry/istextorbinary/issues/292) is a good first step, but there should also be a version which doesn't rely on fs, e.g....
Hi, .gz file buffer is not recognized as binary and 'gz' extension seems to be missing in your binary files list.
I may be missing something obvious, but when I use istextorbinary and build for the browser, I get the following error: ``` > node_modules/istextorbinary/edition-browsers/index.js:2:26: error: Could not resolve "path" (use...
Hello when I try to compile my TypeScript create react app project I get this: Any ideas on how to solve? thanks! ``` Failed to compile. ./node_modules/istextorbinary/edition-browsers/index.js 68:27 Module parse...
I'm developing a VSCode extension, this means CJS Node v18. Running without any build step normally with `const xyz = require('istextorbinary')` works fine. But when building with esbuild and running...
Instead of relying of Node polyfills on the browser, it'd be nice if we could use this library directly on instances of `Uint8Array`. I see we would need to work...
## What is the problem? Our `tsconfig.json` is like this ``` json "compilerOptions": { "moduleResolution": "Bundler", }, ``` But then the import is not recognized 