Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@agility/gatsby-image-agilitycms

Package Overview
Dependencies
Maintainers
4
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@agility/gatsby-image-agilitycms

Gatsby Image wrapper for Agility CMS

  • 1.0.6
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.9K
decreased by-0.05%
Maintainers
4
Weekly downloads
 
Created
Source

NPM version NPM downloads

gatsby-image-agilitycms

With the release of Gatsby V3 and the new Gatsby Image plugin, we were able to create gatsby-image-agilitycms. This is a custom image component that take's images stored within Agility CMS and handles all of the hard parts of displaying responsive images that follow best practices for performance on your website or application.

Getting Started

There are a few steps you need to take before you start using the gatsby-image-agilitycms component.

  1. Update the package.json in your Gatsby project to use the Gatsby V3 and install the new Gatsby Image Plugin:

    • npm install gatsby@latest
    • npm install gatsby-plugin-image
  2. Install gatsby-image-agilitycms and update the gatsby-source-agilitycms plugin to the latest version:

    • npm install @agility/gatsby-image-agilitycms
    • npm install @agility/gatsby-source-agilitycms@latest

Using the AgilityImage Component

To use the AgilityImage Component:

import { AgilityImage } from "@agility/gatsby-image-agilitycms"

The AgilityImage Component accepts the following props:

  1. image = The object of your image from Agility.
  2. layout = Determines the image sizes that are generated, as well as the resizing behavior of the image itself in the browser:
    • constrained
    • fixed
    • fullWidth

Example:

<AgilityImage image={image} layout={fullWidth} />

Live Example

To view a live example of the gatsby-image-agilitycms in action, check out our Gatsby and Agility CMS Starter.

Resources

Agility CMS

Gatsby

Keywords

FAQs

Package last updated on 30 Jul 2021

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc