A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/agility/gatsby-image-agilitycms below:

agility/gatsby-image-agilitycms: Gatsby Image implementation for Agility CMS.

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 takes 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.

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:

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

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:

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

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


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4