Comments (5)
Thanks for the link, currently augment is using the trim2 implementation from that list which looks fairly good performance wise. I'll certainly do a few benchmarks on some more browsers with the suggested trim1 implementation though.
from augment.js.
I'm going to close this issue for now, after running benchmarks against the current implementation and the suggested implementation in IE there was nothing between the two versions performance wise.
from augment.js.
Have you looked at trim2, or did you benchmark trim10 and trim11, too? The one at the very end of the article seems to be the hottest candidate.
from augment.js.
I actually benchmarked trim1, trim2 (which is what is currently implemented) and trim 12, the one at the bottom of the article.
The difference between trim1 & trim2 was negligible. Trim 12 was much slower on any string that had any trailing spaces, and slightly quicker on strings with leading white spaces.
I've pushed the performance test that I did up on a branch, feel free to try it out yourself, perhaps my tests are flawed in some way?
from augment.js.
The tests look good, so yes, I officially draw back the issue :-)
from augment.js.
Related Issues (14)
- Wrong string.trim implementation HOT 1
- Object.create missing on purpose? HOT 1
- Suggestion HOT 1
- Object.getPrototypeOf HOT 12
- Add Object.create HOT 2
- Extended Years not supported by Date.prototype.toISOString HOT 5
- how does this compare to es5-shim? HOT 5
- dontEnum bug HOT 1
- ES5 bind HOT 1
- Potential edge case bugs HOT 4
- Customisable build. HOT 1
- Docs Site Down HOT 1
- Can we add string.include method? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from augment.js.