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

talentlms-reports

v0.1.4

Published

Custom reporting engine for TalentLMS

Downloads

11

Readme

TalentLMS Reports

Custom reporting engine for TalentLMS

Usage

First, instantiate the module with your TalentLMS API credentials

const TalentLMSReports = require('talentlms-reports');
const reports = new TalentLMSReports({
  apiKey: 'Your API key',
  domain: 'Your domain',
});

Then use the async generate method on the instantiated object to generate a report of the desired type

const results = await reports.generate({type: 'group', groupId: '3'});

This package supports some advanced features, such as data caching. See the in-line documentation for more details

Report Types

Group

Takes a groupId and returns the following information for each user in that group:

| Property | Description | | ---- | - | | id | The user's TalentLMS id | | email | The user's email address | | fullName | The user's full name (first name + last name) | | createdOn | Date the user was first created | | lastLogin | When the user last logged in and did something | | courses | Array of course information for the user | | courses[n].id | Id of the course | | courses[n].name | Name of the course | | courses[n].completionPercentage | User's completion percentage between 0-100 | | courses[n].completedOn | Date when the user completed the course, if applicable |

If there is an error generating the report, an object will be returned with an error property that includes error details

Template Notes

NPM Script Commands

Run all tests

npm test

Run only "quick" tests

npm run test-quick

Lint

npm run lint

Lint and automatically fix issues

npm run lint-fix

Project Structure

All code should be added to the src directory. The structure of the source directory should be replicated in the test folder, and all files except for control files should have an associated unit test file that folder

Unit Testing

This project uses the Mocha library to run unit tests. The principles of "Test Driven Development" should be followed when writing code in this project. That is, unit tests should be leveraged as a development tool and all major functionality should have associated unit tests. Code should be written in a way that allows for easy mocking, either by taking all required instantiated libraries as arguments, or by using an internal state that can be modified externally

Slow Tests

External resources should generally be mocked when testing to reduce the time it takes for tests to complete. Long running tests can cause development slowdown, since the unit test suite should be run at will whenever updates are made. However that is not always efficient to do. When external libraries or long processes cannot be mocked the it-slowly test utility should be used. By using itSlowly in place of it within a unit test, the test will automatically be skipped when running unit tests in "quick" mode

Debugging

This project has built-in utilities for debugging unit tests with VSCode (breakpoints, process stepping, etc). Run the Mocha or Mocha Quick debug launch configuration to debug all tests or only quick tests respectively

Configuration

This project uses a standard configuration system that allows for global configuration values to be easily defined and overwritten locally. See the config file in the root directory for more information

EcmaScript vs CommonJs

Currently, all Nodejs projects use the CommonJs syntax because ESM modules are still considered "Experimental" as of Nodejs v14.0 and may be subject to breaking changes in future minor version updates. The existing configuration system also requires use of CommonJs and would need to be refactored significantly to support ESM