Socket
Socket
Sign inDemoInstall

@chakra-ui/image

Package Overview
Dependencies
85
Maintainers
2
Versions
422
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @chakra-ui/image

React component for progressive image loading


Version published
Weekly downloads
552K
increased by4.01%
Maintainers
2
Install size
86.5 kB
Created
Weekly downloads
 

Readme

Source

@chakra-ui/image

The Image component is used to display images.

Installation

yarn add @chakra-ui/image

Import component

import { Image } from "@chakra-ui/image"

Basic Usage

import React from "react"
import { Image } from "@chakra-ui/image"

const Example = () => (
  <Image
    src="photo.png"
    fallbackSrc="placeholdit.com/200x200"
    alt="A Placeholder Image"
  />
)

Fallback support

You can provide a fallback image for when there is an error loading the src of the image. You can also opt out of this behavior by passing the ignoreFallback prop.

<Image
  src="photo.png"
  fallbackSrc="placeholdit.com/200x200"
  alt="A Placeholder Image"
/>

Keywords

FAQs

Last updated on 18 Jul 2023

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc