New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@alexkirsz/gatsby-transformer-sharp

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@alexkirsz/gatsby-transformer-sharp

Gatsby transformer plugin for images using Sharp

2.1.1-rc.8
latest
Source
npm
Version published
Weekly downloads
10
Maintainers
1
Weekly downloads
 
Created
Source

gatsby-transformer-sharp

Creates ImageSharp nodes from image types that are supported by the Sharp image processing library and provides fields in their GraphQL types for processing your images in a variety of ways including resizing, cropping, and creating responsive images.

Live demo (source)

Install

npm install --save gatsby-transformer-sharp gatsby-plugin-sharp

How to use

// In your gatsby-config.js
module.exports = {
  plugins: [`gatsby-plugin-sharp`, `gatsby-transformer-sharp`],
}

Parsing algorithm

It recognizes files with the following extensions as images.

  • jpeg
  • jpg
  • png
  • webp
  • tif
  • tiff

Each image file is parsed into a node of type ImageSharp.

Keywords

gatsby

FAQs

Package last updated on 21 Aug 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts