Updated script that can be controled by Nodejs web app
This commit is contained in:
3
node_modules/component-inherit/.npmignore
generated
vendored
Normal file
3
node_modules/component-inherit/.npmignore
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
components
|
||||
build
|
||||
node_modules
|
5
node_modules/component-inherit/History.md
generated
vendored
Normal file
5
node_modules/component-inherit/History.md
generated
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
|
||||
0.0.2 / 2012-09-03
|
||||
==================
|
||||
|
||||
* fix typo in package.json
|
16
node_modules/component-inherit/Makefile
generated
vendored
Normal file
16
node_modules/component-inherit/Makefile
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
|
||||
build: components index.js
|
||||
@component build
|
||||
|
||||
components:
|
||||
@Component install
|
||||
|
||||
clean:
|
||||
rm -fr build components template.js
|
||||
|
||||
test:
|
||||
@node_modules/.bin/mocha \
|
||||
--require should \
|
||||
--reporter spec
|
||||
|
||||
.PHONY: clean test
|
24
node_modules/component-inherit/Readme.md
generated
vendored
Normal file
24
node_modules/component-inherit/Readme.md
generated
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
# inherit
|
||||
|
||||
Prototype inheritance utility.
|
||||
|
||||
## Installation
|
||||
|
||||
```
|
||||
$ component install component/inherit
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
```js
|
||||
var inherit = require('inherit');
|
||||
|
||||
function Human() {}
|
||||
function Woman() {}
|
||||
|
||||
inherit(Woman, Human);
|
||||
```
|
||||
|
||||
## License
|
||||
|
||||
MIT
|
10
node_modules/component-inherit/component.json
generated
vendored
Normal file
10
node_modules/component-inherit/component.json
generated
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
{
|
||||
"name": "inherit",
|
||||
"description": "Prototype inheritance utility",
|
||||
"version": "0.0.3",
|
||||
"keywords": ["inherit", "utility"],
|
||||
"dependencies": {},
|
||||
"scripts": [
|
||||
"index.js"
|
||||
]
|
||||
}
|
7
node_modules/component-inherit/index.js
generated
vendored
Normal file
7
node_modules/component-inherit/index.js
generated
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
|
||||
module.exports = function(a, b){
|
||||
var fn = function(){};
|
||||
fn.prototype = b.prototype;
|
||||
a.prototype = new fn;
|
||||
a.prototype.constructor = a;
|
||||
};
|
19
node_modules/component-inherit/package.json
generated
vendored
Normal file
19
node_modules/component-inherit/package.json
generated
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "component-inherit",
|
||||
"description": "Prototype inheritance utility",
|
||||
"version": "0.0.3",
|
||||
"keywords": [
|
||||
"inherit",
|
||||
"utility"
|
||||
],
|
||||
"dependencies": {},
|
||||
"component": {
|
||||
"scripts": {
|
||||
"inherit/index.js": "index.js"
|
||||
}
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/component/inherit.git"
|
||||
}
|
||||
}
|
21
node_modules/component-inherit/test/inherit.js
generated
vendored
Normal file
21
node_modules/component-inherit/test/inherit.js
generated
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
|
||||
/**
|
||||
* Module dependencies.
|
||||
*/
|
||||
|
||||
var inherit = require('..');
|
||||
|
||||
describe('inherit(a, b)', function(){
|
||||
it('should inherit b\'s prototype', function(){
|
||||
function Loki(){}
|
||||
function Animal(){}
|
||||
|
||||
Animal.prototype.species = 'unknown';
|
||||
|
||||
inherit(Loki, Animal);
|
||||
|
||||
var loki = new Loki;
|
||||
loki.species.should.equal('unknown');
|
||||
loki.constructor.should.equal(Loki);
|
||||
})
|
||||
})
|
Reference in New Issue
Block a user