New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

membean

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

membean

A NodeJS Client for Membean

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Membean

The ultimate MemBean client API for all your training needs!

Introduction

This package is a versatile Node.js library designed to interact with the MemBean training platform, providing comprehensive access to training sessions, quizzes, spell tests, and more.

Installation

You can install MemBeanTrainingSession via npm:

npm install membean

Usage

Here's a quick guide on how to get started with Membean:

import MemBeanTrainingSession from 'membean';

// Initialize the session with your session ID and authentication token
const session = new MemBeanTrainingSession(sessionId, authToken);

// Listen to events emitted by the session
session.on('new_word', (data) => {
    console.log('New word:', data.word);
    // Handle new word event
});

// Start parsing user state and interacting with the session
session.parseUserState();

For more, see the documentation

Features

  • Event-driven Architecture: Utilize event listeners to react to different states during the training session.
  • Advanced Parsing: Parse detailed information about word learning, quizzes, spell tests, and more.
  • Flexible Advancement: Seamlessly advance through the training session with customizable time spent on each page.
  • Internal Methods: Access internal methods for advanced session manipulation.

Documentation

Classes

MemBeanTrainingSession

The main class representing a MemBean training session.

Events
  • new_word: Emitted when a new word is encountered.
  • restudy: Emitted when a word is being restudied.
  • quiz: Emitted during a quiz session.
  • spelltest: Emitted during a spell test session.
  • take_a_break: Emitted when it's time to take a break.
Methods
  • advance(advancement, timeOnPage): Advance the training session. Params: advancement (internal advancement object), timeOnPage (time spent on page in seconds).
  • _int_advance(event, barrier, args): Internal method for advancing the session.
  • parseUserState(): Parse the user state.
  • _parseUserState(res): Internal method for parsing the user state.
  • parseWordLearn($, type): Parse word learning data.
  • parseQuiz($): Parse quiz data.
  • parseSpellCheck($): Parse spell test data.
  • parseTakeABreak($): Parse take a break data and terminate session.

Contributions

Contributions are welcome! Feel free to submit issues or pull requests on GitHub.

License

This project is licensed under the Creative Commons Attribution 4.0 International License - see the LICENSE file for details.

Author

Written with ❤️ by Aviv Keller redyetidev@gmail.com.

Keywords

FAQs

Package last updated on 24 Mar 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