@codesyntax/ionic-react-header-collapse
TypeScript icon, indicating that this package has built-in type declarations

0.3.0 • Public • Published

ionic-react-header-collapse

Easy to use hook to handle collapse effect on scroll for IonHeader component in React Ionic

Currently the package is in beta phase. Any issue or PR will be appreciated ;)

NPM JavaScript Style Guide

IOS/Android:

Install

npm install --save @codesyntax/ionic-react-header-collapse

Usage

import React, { Component } from 'react';

import { UseIonHeaderCollapse, useIonHeaderCollapse } from '@codesyntax/ionic-react-header-collapse';

const Home: React.FC = () => {
  const { ref } = useIonHeaderCollapse({} as UseIonHeaderCollapse);
  render() {
    return (
      <IonPage>
        <IonHeader ref={ref}>
          <IonToolbar>
            <IonTitle>Ionic header</IonTitle>
          </IonToolbar>
        </IonHeader>
        <IonContent fullscreen>
          ...
        </IonContent>
      </IonPage>
      );
  }
}

License

MIT © CodeSyntax

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.3.07latest

Version History

VersionDownloads (Last 7 Days)Published
0.3.07
0.2.01
0.1.01

Package Sidebar

Install

npm i @codesyntax/ionic-react-header-collapse

Weekly Downloads

9

Version

0.3.0

License

MIT

Unpacked Size

18.6 kB

Total Files

9

Last publish

Collaborators

  • erral
  • ionlizarazu
  • bipoza
  • libargutxi
  • uetxaburu
  • asiercodesyntax