

If the loop is set to true, this parameter is ignored (i.e., this parameter is set to the default value false ). Otherwise, if false, this method calles the resolve() immediately after starting to play the wav file. If true, this method calls the resove() after finishing to play the wav file. If true, the wave file will be played repeatedly until the stop() method is called. Path of a wav file (e.g., "./speech.wav") This method takes a hash object containing the properties as follows: Property The play() method plays a wav file specified to the path parameter. The WavPlayer object has methods as described in sections below. In the code snippet above, the variable player is a WavPlayer object. The node-wav-player will not support Node 4 in the future.Ĭonst player = require ( 'node-wav-player' )

