Skip to content
This repository has been archived by the owner on Oct 10, 2018. It is now read-only.

Using as node module export #26

Open
iamchrismiller opened this issue Feb 21, 2014 · 1 comment
Open

Using as node module export #26

iamchrismiller opened this issue Feb 21, 2014 · 1 comment

Comments

@iamchrismiller
Copy link
Contributor

I would like to use this project as a node module so I can have more control but that would change the existing implementation a bit.

I propose that a new library is created websocket-benchmarker which will contain the main logic and export all the "core" libraries.

This module can depend on the websocket-benchmarker module (to be created) and the commander script will reference the exported module.

I already have this working in a branch export-app but would need to separate the core library out to another repository, so it can still be used as a cli tool.

Check it out here:
https://github.com/iamchrismiller/websocket-bench/tree/export-app

This required me to clean up the process variable leaking into a few places it doesn't need to be and is now passed in to the constructors.

I will write some tests expecting the module is exporting all the required libs correctly and a bit more cleanup this weekend.

Let me know what you think.

@nchaulet
Copy link
Contributor

I thinks is really a good idea 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants