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

billy

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

billy - npm Package Compare versions

Comparing version 2.0.0-beta-2 to 2.0.1

2

HISTORY.md
# Change History
## v2.0.0 (???)
## v2.0.1 (2017-05-11)

@@ -5,0 +5,0 @@ * Initial v2 release

{
"name": "billy",
"version": "2.0.0-beta-2",
"version": "2.0.1",
"description": "A minimal application harness that stays out of your way and out of your code.",

@@ -5,0 +5,0 @@ "author": "Brandon Valosek <bvalosek@gmail.com>",

# billy
> v2 is currently in progress and is NOT yet shipped / final.
> To install it, you need to run `npm install billy@v2-beta`
[![CircleCI](https://circleci.com/gh/bvalosek/billy/tree/master.svg?style=svg)](https://circleci.com/gh/bvalosek/billy/tree/master)

@@ -24,12 +20,9 @@

The primary goal and driving philosophy of Billy is to provide a cohesive and
useful set of patterns for building an application that doesn't creep its way
into your business logic and domain code.
useful set of utilities for building an complex application, without creeping
its way into your business logic and domain code.
It is flexible and generic enough to work great for building server apps,
browser apps, Javascript games, or even CLI utilities.
Billy is not an opinionated framework that permeates all parts of your
codebase, but rather the simple scaffolding that allows you to roll your own
application architecture stack, your way.
Much like [express](https://github.com/visionmedia/express), Billy strives not
to be a framework that permeates all parts of your codebase, but rather the
scaffolding that allows you to roll your own application architecture stack.
### The `Application` instance and the Service Stack

@@ -48,4 +41,38 @@

should be free of all business logic, and should be the only parts of the
aplication that are aware of Billy.
application that are aware of Billy.
```javascript
app.service(AppConfigService);
app.service(PostgresDatabaseService);
app.service(SQSQueueService);
app.service(AuthAPIComponent);
```
If a service implements a `start()` method, it will be called (and `await`-ed)
when you call `app.start()` to boot the application.
```javascript
(async () => {
await app.start();
console.log('all services succesfully instantiated and started -- nice!');
})();
```
All services registered (via `Application#service`) will be instantiated (with
injected constructors, see below) **in the order in which they were
registered**. After all services have been successfully (and synchronously)
instantiated, the `start` method will be called on each one (again, in the
order registered) if implemented. If `start` returns a `Promise`, the app will
wait for it to resolve before continuing.
If any service `throw`s during instantiation or during the `start` method (or
the `Promise` returned is rejected), then the application will abort its
startup.
### The `Container` instance and Dependency Injection

@@ -55,8 +82,12 @@

## Usage
#### Registering Dependencies
> Code Examples
> The various `container.register*` methods
### Environments
#### Resolving Dependencies
> Overview of `new` and `call` on the container, and locals
## Environments
Billy is written to run in modern Javascript environments (ES2017) that support

@@ -67,3 +98,3 @@ the CommonJS module system and the latest ES2017 Spec (e.g, Node 7.10+). It

#### Older JS Runtimes
### Older JS Runtimes

@@ -70,0 +101,0 @@ If you are not on the absolute cutting edge, you'll want to use a transpiled

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