function attacher( options ) {
	var opts;
	var err;

	// Set default options:
	opts = copy( defaults );

	// NOTE: cannot use `arguments.length` check, as `options` may be explicitly passed as `undefined`
	if ( options !== void 0 ) {
		err = validate( opts, options );
		if ( err ) {
			throw err;
		}
	}
	return runner( opts );
}
Attaches a plugin to a remark processor in order to run JavaScript examples.

@param {(void|Options)} [options] - plugin options
@param {string} [options.cwd] - current working directory of the child process
@param {boolean} [options.quiet=false] - boolean indicating whether to silence examples writing to `stdout`, but allow writing to `stderr`
@param {boolean} [options.silent=false] - boolean indicating whether to silence examples writing to both `stdout` and `stderr`
@param {boolean} [options.verbose=true] - boolean indicating whether to print plugin meta information
@param {PositiveInteger} [options.maxBuffer=200*1024] - maximum buffer size for `stdout` and `stderr`
@param {NonNegativeInteger} [options.timeout=0] - maximum number of milliseconds allotted for the execution of each code block
@throws {TypeError} options argument must be an object
@throws {TypeError} must provide valid options
@returns {Function} transform function

@example
var remark = require( 'remark' );

var str = [
    '<section class="usage">',
    '',
    '## Usage',
    '',
    '```javascript',
    'var path = require( "path" );',
    '```',
    '',
    '#### path.posix.join( [...paths] )',
    '',
    '```javascript',
    'var p = path.posix.join( "foo", "bar" );',
    '```',
    '',
    '</section>',
    '',
    '<!-- /.usage -->',
    '',
    '<section class="examples">',
    '',
    '## Examples',
    '',
    '```javascript',
    'console.log( "HELLO WORLD!" );',
    '```',
    '</section>',
    '',
    '<!-- /.examples -->',
    ''
];

remark().use( run ).process( str.join( '\n' ), done );
// => 'HELLO WORLD'

function done( error ) {
    if ( error ) {
        throw error;
    }
}