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

@financial-times/pro-onboarding-tour

v1.2.0

Published

A user tour highlighting various FT Professional features across FT products

Readme

Professional Onboarding Tour

A user tour highlighting various FT Professional features across FT products

Installation

npm install @financial-times/pro-onboarding-tour

Basic Usage

import('@financial-times/pro-onboarding-tour').then(({ init }) => {
  init({ isDebugModeEnabled: false });
});

Development

Tech

  • Node.js / npm
  • Vite
  • Storybook
  • Web components

Directory Structure

├─ src/                       # Source code
│  ├─ index.ts                # Package public entry
│  ├─ definitions/            # global TypeScript type definitions
│  ├─ stories/                # Storybook stories (interaction examples)
│  ├─ vendor/                 # Third-party code
│  └─ lib/                    # Library code
│     ├─ init.ts              # Professional tour initialiser
│     ├─ components/          # UI web components (Overlay, TourStep, etc.)
│     ├─ services/            # Tour logic (navigation, state, loading)
│     └─ utils/               # Small pure helpers (animation, debounce)
|  |- src/test/               # Unit tests
├─ screenshots/               # Screenshots for the README
└─ .storybook/                # Storybook configuration

Setup

git clone [email protected]:Financial-Times/pro-onboarding-tour.git
cd pro-onboarding-tour
npm install

Scripts

npm run build        # Build the library
npm run build:watch  # Watches the files and rebuilds
npm run storybook    # Run Storybook for development
npm run test         # Run tests
npm run lint         # Lint code
npm run format       # Format code

Tests

There are two type of tests - unit tests and Storybook interaction tests

Storybook interaction tests

Storybook interaction tests are written as Storybook stories that include play() functions and use storybook/test helpers and shadow-dom-testing-library to interact with the rendered component inside Storybook's iframe. A representative example is src/stories/TourContainer.stories.ts which contains end-to-end style checks implemented as steps inside play().

Under the hood these interaction tests run with Vitest via Storybook's Vitest addon (see @storybook/addon-vitest and @vitest/browser). More info:

https://storybook.js.org/docs/writing-tests/integrations/vitest-addon https://storybook.js.org/docs/writing-tests/interaction-testing

Where they live

  • Story files with play() tests: src/stories/*.stories.ts
  • The project config includes a separate Vitest project for Storybook tests, check vite.config.js (projects)

Running Storybook interaction tests locally

You can run the tests in two main ways:

  • Dev mode (fast iteration): start Storybook in dev mode in one terminal and run the Storybook vitest project in another.
# Start Storybook dev server
npm run storybook

# Run the Storybook test project
npm run test:storybook
  • Static build (same as CI): build Storybook and then run the Storybook Vitest project against the static build. This mirrors how the tests run in CI and may be more stable for UI tests.
# Build Storybook to `storybook-static`
npm run storybook:build

# Run the Storybook test project (it will pick up the static build where configured)
npm run test:storybook

How CI runs them

The CircleCI configuration builds Storybook (npm run storybook:build) and then runs the Storybook UI tests in a Playwright-enabled executor. See .circleci/config.yml jobs build-storybook and test-ui which run npm run storybook:build and npm run test:storybook respectively.

Unit tests

This repository keeps its unit tests under src/test/. Unit tests run with Vitest using the jsdom environment.

Current unit tests (under src/test/) include:

  • src/test/NavigationService.test.ts
  • src/test/Overlay.test.ts
  • src/test/QueryParameterService.test.ts
  • src/test/StepsLoader.test.ts
  • src/test/TourContainer.test.ts
  • src/test/TourStateManager.test.ts
  • src/test/TourStep.test.ts

Running unit tests

  • Run all tests (default Vitest project):
npm run test
  • Run only the unit Vitest project (recommended for fast, focused runs):
npm run test:unit
  • Run tests by name (match test title):
npm run test:unit -- -t "Overlay"

Local dev

  • Run integrated app locally
  • In the root of this package run npm link to create a global link
  • In the root of your project run npm link @financial-times/pro-onboarding-tour
  • Use npm run build:watch to watch the changes during development