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

@ayana/bento

Package Overview
Dependencies
Maintainers
2
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ayana/bento

Modular runtime framework designed to solve complex tasks

  • 1.0.0-alpha6
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.2K
increased by899.55%
Maintainers
2
Weekly downloads
 
Created
Source

Bento npm (scoped) Discord install size

Documentation

Bento is a NodeJS framework designed to make creating and maintaing complex projects a simple and fast process.

What does Bento do:

  • Component lifecycle state and management
  • Provides consistent API for all components
  • Config Loading API
  • Event API
  • Defines strict, opinionated, rules

What is a Bento Component?

Bento indroduces a concept of components. Components are logical chunks of code that all work together to provide your application to the world.

Components should not take on more then required. (IE: instead of having one component for connecting to Discord and processing messages. Have two, one for the connection and one that handles messages)

How to use Bento (IN-PROGRESS)

Using bento is pretty simple. First import and initilize bento and any plugins you wish to use. Then simply add plugins to bento

'use strict';

import * as path from 'path';

import { Bento, FSComponentLoader } from '@ayana/bento';

// Create a Bento instance
const bento = new Bento();

// Create FSComponentLoader
// NOTE: Keep in mind all FSComponentLoader does is find Bento components in the path provided
// Instantiates them and calls bento.addPrimaryComponent or bento.addSecondaryComponent
// Behind the scenes
const loader = new FSComponentLoader({
	primary: path.resolve(__dirname, 'modules'),
});

// Apply plugin to Bento.
// NOTE: Keep in mind that addPlugin is async and you should .catch any errors
bento.addPlugin(loader).catch(e => {
	console.log('Sad day', e);
});

FAQs

Package last updated on 15 Nov 2018

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