8000 Adding npm support via package.json · JavaScriptIOT/dsp.js@b4dc02e · GitHub
[go: up one dir, main page]

Skip to content

Commit b4dc02e

Browse files
committed
Adding npm support via package.json
1 parent d39af34 commit b4dc02e

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

dsp.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2300,3 +2300,23 @@ Reverb.prototype.process = function (interleavedSamples){
23002300
return outputSamples;
23012301
};
23022302

2303+
if (module && typeof module.exports !== 'undefined') {
2304+
module.exports = {
2305+
DSP: DSP,
2306+
DFT: DFT,
2307+
FFT: FFT,
2308+
RFFT: RFFT,
2309+
Sampler: Sampler,
2310+
Oscillator: Oscillator,
2311+
ADSR: ADSR,
2312+
IIRFilter: IIRFilter,
2313+
IIRFilter2: IIRFilter2,
2314+
WindowFunction: WindowFunction,
2315+
sinh: sinh,
2316+
Biquad: Biquad,
2317+
GraphicalEq: GraphicalEq,
2318+
MultiDelay: MultiDelay,
2319+
SingleDelay: SingleDelay,
2320+
Reverb: Reverb
2321+
};
2322+
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "dsp.js",
33
"version": "1.0.0",
44
"description": "Digital Signal Processing for Javascript http://weare.buildingsky.net",
5-
"main": "index.js",
5+
"main": "dsp.js",
66
"directories": {
77
"example": "examples",
88
"test": "test"

0 commit comments

Comments
 (0)
0