Tools used by filestack
npm install @filestack/tools
Javascript tools used by filestack
- Api Documentation
- Tools included
- How to use
- NodeJS
- Browsers
- ES module
- UMD module
- SRI
- Rollup support
- Versioning
- Contributing
Api documentations is available on github pages
- file - file manipulation tools like exif removal, mimetypes operations etc
- filterJpeg - filter jpeg file metadata
- extensionToMime - convert extension to mimetype
- getMimetype - returns mimetype based on magicbytes and extension
- isAcceptable - checks if ext or mime is in acceptable array
``js`
import { filterJpeg } from 'filestack-tools';
filterJpeg(FILE_BUFFER, options);
#### ES module
`js`
import { filterJpeg } from 'filestack-tools';
filterJpeg(BLOB, options);
#### UMD module
`HTML`
where {MAJOR_VERSION} is one of the MAJOR versions of the filestack-js ie:
`HTML`
#### SRI
Subresource Integrity (SRI) is a security feature that enables browsers to verify that files they fetch (for example, from a CDN) are delivered without unexpected manipulation. It works by allowing you to provide a cryptographic hash that a fetched file must match
To obtain sri hashes for filestack-tools library check manifest.json file on CDN:
``
https://static.filestackapi.com/filestack-tools/{LIBRARY_VERSION}/manifest.json
`HTML`
Where {LIBRARY_VERSION} is currently used library version and {FILE_HASH}` is one of the hashes from integrity field in manifest.json file
When using with rollup, set resolve plugin with option browser:true
We use SemVer for versioning. For the versions available, see the tags on this repository.
We follow the conventional commits specification to ensure consistent commit messages and changelog formatting.