mirror of
https://github.com/lovell/sharp.git
synced 2025-07-09 10:30:15 +02:00
Docs: update new Buffer() to Buffer.from() (#1273)
This commit is contained in:
parent
1999c7103c
commit
3d7e8ef432
@ -48,7 +48,7 @@ sharp('input.jpg')
|
|||||||
```
|
```
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
const roundedCorners = new Buffer(
|
const roundedCorners = Buffer.from(
|
||||||
'<svg><rect x="0" y="0" width="200" height="200" rx="50" ry="50"/></svg>'
|
'<svg><rect x="0" y="0" width="200" height="200" rx="50" ry="50"/></svg>'
|
||||||
);
|
);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user