Extract token trimming into a pipeline function.

The current implementation does not work well for non-latin based
languages.
Add lunr.Pipeline.prototype.reset.

Resets an instance of lunr.Pipeline, emptying out any added pipeline
functions. This will be useful when adding lunr language extensions.
Add Index.prototype.use for including plugins.

A plugin is just a function that is applied with the current index as
the context and the first argument.
Fix accidental globals in tests.