npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

react-js-simple-calendar

v2.1.2

Published

![Logo](https://surely-assets.s3.ap-southeast-1.amazonaws.com/vecteezy_calendar-icon-vector.png) # react-js-simple-calendar

Readme

Logo

react-js-simple-calendar

npm version

🧭 A simple, customizable React calendar component for modern web applications.

react-js-simple-calendar is a simple, easy-to-use React calendar component designed for modern web applications.

🌟 Features

  • 🧩 Easy to integrate into any React project
  • 🌗 Light and dark themes
  • 📅 Minimum and maximum date restrictions
  • ⚡ Callback on date selection
  • 🕒 Supports both string and Date objects for date props
  • 📱 Fully responsive design
  • 🔍 Advanced mode with year/month/day navigation

Installation (for standard modern project)

  npm i react-js-simple-calendar

Example Usage

Below is a simple example demonstrating how to import and use the Calendar component from the react-js-simple-calendar package in a React application:

import React from 'react';
import { Calendar } from 'react-js-simple-calendar';

function App() {
  return (
    <div>
      <h1>My Calendar App</h1>
      <Calendar />
    </div>
  );
}

export default App;

📦 Props

| Prop | Type | Default | Description | |:----------|:----------|:------------|:----------------| | date | Date | new Date() | Sets the initial selected date. | | onChange | function | — | Callback that returns the selected date when changed. | | theme | string | "light" | Calendar theme. Accepts "light" or "dark". | | minDate | Date | — | Minimum selectable date. Dates before this will be disabled. | | maxDate | Date | — | Maximum selectable date. Dates after this will be disabled. | | mode | string | "default" | Defines calendar display mode. Accepts "default" or "advanced" for full year/month/day navigation. | | minYear | number | currentYear | The earliest year displayed in the calendar year view. | | maxYear | number | currentYear + 70 | The latest year displayed in the calendar year view. |

🖼️ Advanced Usage

You can customize the calendar, handle date changes, and apply restrictions like minimum and maximum selectable dates. Here's an example:

import React, { useState } from "react";
import { Calendar } from "react-js-simple-calendar";

function App() {
  const [selectedDate, setSelectedDate] = useState(new Date());

  // Handle date selection
  const handleDateChange = (date) => {
    setSelectedDate(date);
    console.log("Selected date:", date);
  };

  return (
    <div>
      <h1>Selected Date: {selectedDate.toDateString()}</h1>

       <Calendar
          date={selectedDate}          // Initial selected date
          onChange={handleDateChange}  // Callback on date change
          theme="dark"                 // Choose "light" or "dark"
          minDate="2023-01-01"         // Disable dates before this
          maxDate="2025-12-31"         // Disable dates after this
          mode="advanced"              // Enables advanced view
          minYear={2020}               // Earliest year to show
          maxYear={2030}               // Latest year to show
        />
    </div>
  );
}

export default App;

🔧 Contributing

Contributions are always welcome! Whether it's fixing bugs, improving documentation, or adding new features, your help is appreciated.

How to Contribute

  1. Fork the repository
    Click the "Fork" button at the top-right of the repository page.

  2. Clone your fork

    git clone https://github.com/ujjalCha1/react-js-simple-calendar
    cd react-js-simple-calendar
    

💬 Connect

👤 Author: Ujjal Chatterjee
📦 NPM: react-js-simple-calendar
GitHub Repo: https://github.com/ujjalCha1/react-js-simple-calendar