Test substring vs endsWith where you have to calculate the length of the string for substring operation.
sdfs
Compare methods.
Quem quebra mais rápido?
New benchmark Your benchmarks
Source code: GitHub/MeasureThat.net
Report issues: MeasureThat.net/Issues
Based on: Benchmark.js (v2.1.1)
Facebook page: https://www.facebook.com/MeasureThat.Net