sindresorhus / is-jpg
Check if a Buffer/Uint8Array is a JPEG image
☆27Updated 2 years ago
Related projects: ⓘ
- Check if a Buffer/Uint8Array is a GIF image☆29Updated 2 years ago
- Break out of a promise chain☆21Updated 3 years ago
- Invert the key/value of an object. Example: {foo: 'bar'} → {bar: 'foo'}☆36Updated 2 years ago
- Check if a path is a file, directory, or symlink☆75Updated last month
- Strip the final newline character from a string/buffer☆33Updated 4 months ago
- Strip redundant indentation and indent the string☆54Updated 3 years ago
- Check if the process is running as root user, for example, one started with `sudo`☆79Updated 2 years ago
- Get the visual width of the widest line in a string - the number of columns required to display it☆36Updated 10 months ago
- Define multiple non-enumerable properties at once. Uses `Object.defineProperty` when available; falls back to standard assignment in olde…☆21Updated last month
- Returns the directory used by NPM for globally installed NPM packages.☆35Updated 5 years ago
- Get the directory of globally installed packages and binaries☆75Updated 10 months ago
- Returns an array with only the unique values from all given arrays using strict equality for comparisons.☆45Updated 2 years ago
- Check if something is a promise☆46Updated 3 years ago
- Detect the dominant newline character of a string☆55Updated 11 months ago
- Check if something is a generator function☆23Updated 2 years ago
- Create ansi colors by passing open and close codes.☆18Updated 5 months ago
- Truncate a semver version: 1.2.3 → 1.2.0☆17Updated 2 years ago
- Returns an array filled with the specified input☆43Updated 2 years ago
- Check if your code is running as an npm or yarn script☆64Updated 3 years ago
- Rename a function☆45Updated 10 months ago
- Wait for a specified number of promises to be fulfilled☆34Updated 10 months ago
- Get a random key from an object☆18Updated 2 months ago
- Check if a path is the current working directory☆19Updated 3 years ago
- Create a Vinyl file from an actual file☆41Updated last year
- tar plugin for decompress☆16Updated 3 years ago
- Import a module like with `require()` but from a given path☆86Updated 2 years ago
- Convert matching double-quotes to single-quotes: `I "love" unicorns` → `I 'love' unicorns`☆55Updated 2 years ago
- Object.keys shim☆45Updated last year
- Prepend `https://` to humanized URLs like `sindresorhus.com` and `localhost`☆62Updated 3 years ago
- Add XO to your project☆47Updated 10 months ago