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

react-native-coachmark

Package Overview
Dependencies
Maintainers
0
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-coachmark

![NPM Version](https://badge.fury.io/js/react-native-coachmark.svg) [![CircleCI](https://circleci.com/gh/traveloka/react-native-coachmark/tree/master.svg?style=shield&circle-token=ab2fa2d1fdea74636ee3132e16c82003cdc95383)](https://circleci.com/gh/travelok

  • 0.3.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
112
increased by3.7%
Maintainers
0
Weekly downloads
 
Created
Source

React Native Coachmark

NPM Version CircleCI PRs Welcome

preview

Installation

yarn

yarn add react-native-coachmark

npm

npm i react-native-coachmark --save

Getting Started

Basic Usage

import React from 'react';
import { Coachmark } from 'react-native-coachmark';

export default function AwesomeScreen() {
  return (
    <Page>
      <Header>
        <Coachmark autoShow message="Click here to save your page!">
          <ButtonBookmark>
        </Coachmark>
      </Header>
    </Page>
  );
}

Example

preview

View on Expo!

Documentation

- Coachmark

Importing
var Coachmark = require('react-native-coachmark').Coachmark; // ES5

import { Coachmark } from 'react-native-coachmark'; // ES6
Props
PropertyTypeDefault ValueDescription
messagestringnoneoptional
autoShowbooleannoneto show the coachmark when mounting
onShowfunctionnonewill be called when coachmark is showing
onHidefunctionnonewill be called when coachmark is hidden
isAnchorReadybooleantruea value to force coachmark not being shown yet
renderArrow(options: { x: number; position: CoachmarkPosition }) => ReactElementnonepass a custom coachmark arrow to override the default one
renderContent(options: { x: number; position: CoachmarkPosition }) => ReactElementnonepass a custom coachmark content to override the default one
Methods
MethodsDescription
show() => Promisea function to trigger show the coachmark

Roadmap

  • Auto load and save in AsyncStorage
  • Show coachmark only when in view port
  • Custom render arrow and content

Contributing

We'd to have your helping hand on this package! Feel free to PR's, add issues or give feedback!

Credits

Written by Jacky Wijaya (jekiwijaya) at Traveloka.

Keywords

FAQs

Package last updated on 10 Jul 2024

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