dog-picture
Advanced tools
Comparing version 0.0.1 to 0.0.2
16
index.js
@@ -1,8 +0,8 @@ | ||
var fs = require('fs'); | ||
var dog = fs.readFileSync(__dirname + '/dog.jpg', 'hex'); | ||
dog = new BUffer(dog.toString(), 'hex').toString('base64'); | ||
dog = 'data:image/jpeg;base64,' + dog; | ||
var img = document.createElement('img'); | ||
img.setAttribute('src', dog); | ||
img.setAttribute('class', 'dog-picture'); | ||
document.body.appendChild(img); | ||
var fs = require('fs') | ||
var dog = fs.readFileSync(__dirname + '/dog.jpg', 'hex') | ||
dog = new Buffer(dog.toString(), 'hex').toString('base64') | ||
dog = 'data:image/jpeg;base64,' + dog | ||
var img = document.createElement('img') | ||
img.setAttribute('src', dog) | ||
img.setAttribute('class', 'dog-picture') | ||
document.body.appendChild(img) |
{ | ||
"name": "dog-picture", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"description": "require('dog-picture')", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -5,5 +5,9 @@ # dog-picture | ||
`npm -i --save dog-picture` | ||
`require('dog-picture')` | ||
```bash | ||
npm -i --save dog-picture | ||
``` | ||
```js | ||
require('dog-picture') | ||
``` | ||
heavily ~inspired~ borrowed from [Max Ogden's](https://github.com/maxogden) [cat-picture](https://github.com/maxogden/cat-picture). | ||
heavily ~~inspired~~ borrowed from [max ogden's](https://github.com/maxogden) [cat-picture](https://github.com/maxogden/cat-picture). |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
129953
13