Modular programming is a software design technique that emphasizes separating the functionality of a program into independent, interchangeable modules, such that each contains everything necessary to execute only one aspect of the desired functionality
noun
the use of individually distinct functional units, as in assembling a computer application .
node package manager
Package manager for the web
fits into a problem pattern or category
has been implemented in other domain specific ways
it's encapsulate-able
encapsulate the candidate functionality in place
identify the problem category the functionality solves
genericize the implementation
eliminate side effects
start a new git repo
`npm/bower link`
unit tests are a must
documentation in readme.md
package.json `author`, `maintainers`, and `contributors` properties
$ git init
$ git remote add origin <git-url>
~/projects/typeoOf $ npm link
...
~/projects/myApp $ npm link typeOf
~/projects/typeoOf $ bower link
...
~/projects/myApp $ bower link typeOf
describe('typeOf()', () => {
it('should return the `type` of a thing', () => {
...
});
});
#The Awesome `typeOf` module!
give it something and watch it return it's type.
```
typeOf(new Date()) // 'date' No Way!!!!
```
{
...
author: "Gérald Caussé <bishop.causse@ldschurch.org>",
maintainers: [
"Portfolio Name <DL-Portfolio@ldschurch.org>",
"Gary E. Stevenson <bishop.stevenson@ldschurch.org>",
"Gérald Caussé <bishop.causse@ldschurch.org>",
"Dean M. Davies <bishop.causse@ldschurch.org>"
}
],
contributors: [{
"name": "David A. Bednar",
"email": "elder.bednar@ldschurch.org"
}]
...
}
~/projects/my-module $ yo lds-node:module
$ git tag -a v1.0.1 -m "added additional use case"
$ npm publish
$ bower register package-name git-endpoint
$ npm install <package-name> --save
$ bower install <package-name> --save