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

apm-mimas

Package Overview
Dependencies
Maintainers
3
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apm-mimas

A React component that takes an image endpoint from APM's APIs and returns a proper image with srcset.

  • 0.1.9
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
16
increased by23.08%
Maintainers
3
Weekly downloads
 
Created
Source

apm-mimas

Takes an endpoint from APM's Images API and turns it into an <img /> object with srcset.

Installation

Simply run the command npm i apm-mimas or yarn add apm-mimas.

Usage

In files were you want to use the Image component, put import { Image } from 'apm-mimas' at the top of your file.

Available Properties

  • image: a JSON image object returned from APM's Images API
  • aspectRatio: used to specify which size of image you'd like returned from the API. Useless for other types of images
  • alt: set the image's alt attribute. Will override the automatic value of image.short_caption if applicable
  • elementClass: provide a custom className to this object, for use in styling, custom JavaScript, and so on
  • fallbackSrcSet: provide an alternative srcset attribute if you're not using the Images API
  • fallbackSrc: provide an alternative src attribute if you're not using the Images API.
  • sizes: provide guildelines for what the image size should be depending on various media queries

Keywords

FAQs

Package last updated on 07 May 2019

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