https://github.com/yakovenkodenis/node-remote-base64
Fetch remote data to base64 format using Promises.
https://github.com/yakovenkodenis/node-remote-base64
base64 base64image fetch node nodejs
Last synced: 3 months ago
JSON representation
Fetch remote data to base64 format using Promises.
- Host: GitHub
- URL: https://github.com/yakovenkodenis/node-remote-base64
- Owner: yakovenkodenis
- License: mit
- Created: 2016-11-23T20:57:47.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-11-24T12:53:30.000Z (over 9 years ago)
- Last Synced: 2025-08-25T01:43:37.033Z (10 months ago)
- Topics: base64, base64image, fetch, node, nodejs
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/node-remote-base64
- Size: 12.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Remote Base64 [](https://travis-ci.org/yakovenkodenis/node-remote-base64)
======
## Installation
`npm install --save node-remote-base64`
## Usage
#### ES5
```javascript
const remoteBase64 = require('node-remote-base64');
const getBase64 = () =>
remoteBase65('http://placehold.it/100x100')
.then(b64data => console.log(b64data))
.catch(err => console.log(err));
```
#### Babel ES7 (Async/Await)
```javascript
import remoteBase64 from 'node-remote-base64';
const getBase64 = async () => {
const b64data = await remoteBase65('http://placehold.it/100x100');
console.log(b64data);
}
```
## Tests
`npm test`
## Contributing
In lieu of a formal style guide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.