bleroy / lunr-core

A port of LUNR.js to .NET Core
MIT License
565 stars 24 forks source link

Various Improvements #32

Closed iamcarbon closed 3 years ago

iamcarbon commented 3 years ago
iamcarbon commented 3 years ago

Ready for review / feedback.

iamcarbon commented 3 years ago

Agreed on keeping the library safe. The allocation reductions for StringBuilder.Append are unmarkable. There's a small perf improvement using Contains on modern runtimes as it skips logic to get the index position.

I'll do some benchmarking and figure out how many allocations we're saving with the LINQ changes soon -- and open up a new PR with a clean history.