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

a-tour

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

a-tour

An annoying tutorial helper

  • 0.0.3
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Zero Dependencies One Liner Feature Tutorial Helper

User Onboarding, Product Walkthrough, Feature Guide, whatever you call it, is annoying but PM likes it.

Not Very Ready

This thing is working in progress. Everything may change during the development. Use it at your own discretion.

👉Demo👈

Install

npm i a-tour

Usage

    new aTour({
      id: 'my-guide', // multiple guide supported
      steps: [
        {
          target: '#app > div > div.page-header',
          hint: 'This is an awesome page header',
          title: 'My page header',
        },
      ],
    }).start()

API

  • new ATour(options) // options has following properties

    • id: string // an identifier
    • container: HTMLElement | string | (() => HTMLElement) // a HTML node, a selector or a function that returns a html node
    • steps: Step[] // properties as below
      • target: string // a css selector targeting the element you want to highlight
      • title: string
      • hint: string
      • clickTargetAsNext?: boolean // enable mouse event on target and click it as "next" button
      • delay?: number // a delay in milliseconds, in case the target element is not yet visible on DOM for reason like, data loading or invoking a modal
      • noPrev?: boolean // disable "prev" button for this step
  • instance.start() // starts the guide

  • instance.stop() // quite the guide programmatically

TODO

  • handle scroll
  • multiple guides
  • hint arrow
  • hyper link in hint

FAQs

Package last updated on 14 Jul 2022

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