Skip to content

Repository files navigation

Responsive Image Component

Overview

This is a custom React component library for creating responsive images with maintained aspect ratio. The component utilizes the next/image module for efficient image optimization and delivery.

  • seo
  • aspect-ratio

Features

  • Maintained Aspect Ratio: Images maintain their aspect ratio across different screen sizes.
  • Flexibility: The component can be easily integrated into various projects and layouts.
  • Reusability: Designed to be reusable across different parts of a project.

Installation

Usage

  1. Import the RespImage component into your project:
import RespImage from "@your-username/resp-image";
  1. Use the RespImage component in your React components:
<RespImage src="/path/to/your/image.jpg" alt="Image Alt Text" />

Props

  • src: (string, required) The path or URL to the image.
  • alt: (string, required) The alternative text for the image.
  • ... working on it there will be more

Example

import RespImage from "@your-username/resp-image";

function MyComponent() {
  return (
    <div>
      <h1>Responsive Images</h1>
      <RespImage src="/path/to/image.jpg" alt="Test Image" />
    </div>
  );
}

export default MyComponent;

Contributing

Contributions are welcome! If you have any ideas, improvements, or issues, feel free to open an issue or submit a pull request.

License

This project is licensed under the ...


About

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages