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 🙏

© 2024 – Pkg Stats / Ryan Hefner

personality-behaviors

v1.1.0

Published

Obtain behaviors from Personality Insights' profiles. Behaviors present in this component are based on scientific research.

Downloads

4

Readme

Behaviors for Personality Insights

last-release npm-version npm-license Build Status codecov.io npm-downloads

Obtain behaviors from Personality Insights' profiles. Behaviors present in this component are based on scientific research.

Getting Started

  1. Require and instance personality-behaviors component
const PersonalityBehaviors = require('personality-behaviors');
const personalityBehaviors = new PersonalityBehaviors({ locale: 'es' });
  1. Get profile's behavior
const profile = require('./resources/profile');
const behaviors = personalityBehaviors.behaviors(profile);
  1. Render behaviors somewhere! Try rendering them as cards!

See the complete example code or try it live

More Features

There are more features available such as:

  • Including the component as a browser script. Component will be exported as the global variable PersonalityBehaviors.

  • Filtering behaviors by category, industry or both!

const financeBehaviors = personalityBehaviors.behaviors(profile, { category: ['finance'] });
const mediaBehaviors = personalityBehaviors.behaviors(profile, { industry: ['media'] });
  • Get category and industry listings
const industries = personalityBehaviors.industries();
const categories = personalityBehaviors.categories();
  • Formatting descriptions in html or markdown optionally!
const personalityBehaviors = new PersonalityBehaviors({ format:'html' });
const mediaBehaviors = personalityBehaviors.behaviors(profile, { industry: ['media'] });

API Methods

The available methods are the following ones:

  • constructor :: (Options) -> PersonalityBehaviors - Obtain an instance of PersonalityBehaviors.
  • behaviors :: (Profile, FilterOptions) -> [Behavior] - Calculate the list of behaviors that apply to the given Personality Insights Profile.
  • categories :: [Category] - List of categories available.
  • industries :: [Industry] - List of industries available.

Definitions:

  • Profile is a IBM Watson Personality Insights profile which is basically the service JSON output, parsed into a JavaScript Object.
  • Options are options for the behaviors component. Available options are:
    • locale - A String with the locale used to generate the labels.
    • format - A String with format. Available formats are ["plain", "html", "markdown"].
  • FilterOptions are filter options for the behaviors matching.
    • category - A String or [String] with the categories to include.
    • industry - A String or [String] with the industries to include.
  • Category and Industry are Strings.