Add createFromBuffer to planned breaking changes
authorKevin Sawicki <kevinsawicki@gmail.com>
Wed, 14 Dec 2016 18:12:37 +0000 (10:12 -0800)
committerKevin Sawicki <kevinsawicki@gmail.com>
Wed, 14 Dec 2016 18:12:37 +0000 (10:12 -0800)
docs/api/native-image.md
docs/tutorial/planned-breaking-changes.md

index 4421eb1..4ba3498 100644 (file)
@@ -137,10 +137,9 @@ let image = nativeImage.createFromPath('/Users/somebody/images/icon.png')
 console.log(image)
 ```
 
-### `nativeImage.createFromBuffer(buffer[, scaleFactor, options])`
+### `nativeImage.createFromBuffer(buffer[, options])`
 
 * `buffer` [Buffer][buffer]
-* `scaleFactor` Double (optional)
 * `options` Object (optional)
   * `width` Integer (optional)
   * `height` Integer (optional)
index 44b837e..681c66f 100644 (file)
@@ -69,6 +69,13 @@ nativeImage.toPNG()
 nativeImage.toJpeg()
 // Replace with
 nativeImage.toJPEG()
+
+// Deprecated
+nativeImage.createFromBuffer(buffer, 1.0)
+// Replace with
+nativeImage.createFromBuffer(buffer, {
+  scaleFactor: 1.0
+})
 ```
 
 ## `process`