function createRegExp( exts ) {
	var re;
	var i;

	re = '^index(?:';
	for ( i = 0; i < exts.length; i++ ) {
		re += replace( exts[ i ], RE_REGEXP_CHARS, '\\$&' );
		if ( i < exts.length-1 ) {
			re += '|';
		}
	}
	re += ')$';
	return new RegExp( re );
}
Returns a regular expression for matching an `index` file.

## Notes

-   Example output:

    ```text
    /^index(?:\.js|\.node)$/
    ```

@private
@param {Array} exts - supported `require` extensions
@returns {RegExp} regular expression