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 🙏

© 2026 – Pkg Stats / Ryan Hefner

bukazu-portal-react

v3.7.0

Published

A package for loading the calendar and search module from bukazu loading into a react app.

Readme

bukazu-portal-react

A React component library that embeds the Bukazu booking portal — calendar, search, and reviews modules — directly into any React application.


What is Bukazu?

Bukazu is an online booking and property-management platform for holiday rentals. It provides a fully-managed back-end (availability calendars, pricing, booking forms, guest reviews) and exposes that data through a GraphQL API. This library is the official front-end component that lets you surface Bukazu data on your own website without building the UI from scratch.

Modules included

| Module | Description | |--------|-------------| | Calendar | Interactive availability calendar with arrival/departure highlighting, pricing, discount indicators, and an embedded booking form | | Search | Filterable property search with grid/list view, pagination, and customisable filter fields | | Reviews | Display guest reviews and aggregate score for a specific property |


Installation

npm install bukazu-portal-react

Then import the bundled stylesheet once in your application entry point:

import 'bukazu-portal-react/index.css';

Quick Start

The default export is the Portal component. Pass your portal code (and optionally an object code) to load the correct module.

import Portal from 'bukazu-portal-react';
import 'bukazu-portal-react/index.css';

function App() {
  return (
    <Portal
      portalCode="YOUR_PORTAL_CODE"
      objectCode="YOUR_OBJECT_CODE"
      locale="en"
    />
  );
}

Usage by Module

Calendar (availability + booking form)

Render the calendar for a specific property by supplying both portalCode and objectCode. No pageType is needed — the calendar is the default when an objectCode is present.

<Portal
  portalCode="YOUR_PORTAL_CODE"
  objectCode="YOUR_OBJECT_CODE"
  locale="en"
/>

Search

Render the property search page by omitting objectCode. You can pre-populate filter values via the filters prop.

<Portal
  portalCode="YOUR_PORTAL_CODE"
  locale="en"
  filters={{
    persons_min: '2',
    arrival_date: '2024-07-01',
    departure_date: '2024-07-14'
  }}
/>

Reviews

Render the reviews page for a specific property by passing objectCode together with pageType="reviews".

<Portal
  portalCode="YOUR_PORTAL_CODE"
  objectCode="YOUR_OBJECT_CODE"
  pageType="reviews"
  locale="en"
/>

Props

| Prop | Type | Required | Default | Description | |------|------|----------|---------|-------------| | portalCode | string | ✅ | — | Your Bukazu portal identifier. Find it in your Bukazu back-office. | | objectCode | string | — | — | The property code. Required for the Calendar and Reviews modules. | | pageType | string | — | — | Set to "reviews" to render the Reviews module. | | locale | string | — | "en" | Display language. Supported values: en, nl, de, fr, es, it. | | filters | FiltersType | — | {} | Pre-set filter values for the Search module (see below). | | api_url | string | — | https://api.bukazu.com/graphql | Override the GraphQL endpoint (useful for staging environments). |

filters object

All filter keys are optional strings/arrays.

| Key | Type | Description | |-----|------|-------------| | arrival_date | string | Pre-selected arrival date (YYYY-MM-DD) | | departure_date | string | Pre-selected departure date (YYYY-MM-DD) | | persons_min | string | Minimum number of persons | | persons_max | string | Maximum number of persons | | bedrooms_min | string | Minimum number of bedrooms | | bathrooms_min | string | Minimum number of bathrooms | | weekprice_max | string | Maximum weekly price | | countries | any | Filter by country | | regions | any | Filter by region | | cities | string | Filter by city | | properties | any[] | Filter by property characteristics | | extra_search | string | Free-text search term |


Colour Customisation

Colours are defined in your Bukazu back-office and applied automatically as CSS custom properties on the page root. You can also override them in your own stylesheet:

:root {
  --bukazu-button:      #0055a5;  /* primary action button  */
  --bukazu-button_cta:  #e94e1b;  /* call-to-action button  */
  --bukazu-arrival:     #c8f5c8;  /* arrival day highlight  */
  --bukazu-departure:   #ffd6d6;  /* departure day highlight */
  --bukazu-booked:      #d6d6d6;  /* booked / unavailable   */
  --bukazu-cell:        #f0f8ff;  /* available day cell     */
  --bukazu-discount:    #fff3cd;  /* discounted price cell  */
}

Supported Languages

Pass one of the following BCP-47 locale codes to the locale prop:

| Code | Language | |------|----------| | en | English (default) | | nl | Dutch | | de | German | | fr | French | | es | Spanish | | it | Italian |


Integration Troubleshooting

The component performs basic validation on startup and will display an error message in place of the portal if any of the following conditions are detected.

Common errors

| Symptom | Cause | Solution | |---------|-------|----------| | "No portal code is specified" | portalCode prop is missing or empty | Supply the portal code from your Bukazu back-office | | "Invalid locale" | An unsupported locale string was passed | Use one of: en, nl, de, fr, es, it | | "is not a valid page" | pageType has an unrecognised value | Only "reviews" is a valid pageType; omit the prop for the default modules | | Blank / nothing rendered | CSS stylesheet not imported | Add import 'bukazu-portal-react/index.css' to your entry point | | API errors in the console | Invalid portal or object code | Double-check the codes in your Bukazu back-office |

Reporting Issues

If you encounter a bug or have a feature request, please open an issue on GitHub and include:

  1. The version of bukazu-portal-react you are using (npm list bukazu-portal-react)
  2. Your React version
  3. A minimal reproducible example
  4. Any console errors or network errors from the browser DevTools

Bundle Analysis

The production build uses Terser for advanced minification (with console/debugger stripping and Safari 10 mangling compatibility) and reports gzip sizes for all output files.

To generate an interactive visual bundle report, run:

npm run build:analyze

This builds the library with ANALYZE=true, which activates rollup-plugin-visualizer and writes a build/stats.html report. The report opens automatically in your browser and shows the size breakdown of every module in the bundle (including gzip and Brotli sizes), making it easy to identify large dependencies that are candidates for further size reduction.


License

MIT © Bukazu