Comments (4)
Canvas still has wider support than SVG, especially in older Firefox versions. However, I did add a SVG renderer and it looks like there is a significant speed up:
Browser | Images | Canvas | SVG | SVG speedup |
---|---|---|---|---|
Chrome 30 | 50 | 13 ops/sec | 152 ops/sec | 12x |
Chrome 30 | 100 | 6.5 ops/sec | 80.8 ops/sec | 12x |
Chrome 30 | 200 | 3.3 ops/sec | 43.3 ops/sec | 13x |
Firefox 24 | 50 | 2.4 ops/sec | 50 ops/sec | 21x |
Firefox 24 | 100 | 1.2 ops/sec | 26.8 ops/sec | 22x |
Firefox 24 | 200 | 0.6 ops/sec | 13.5 ops/sec | 23x |
I'll continue working on the SVG renderer and it may be included in the next version.
from holder.
I think going forward and releasing an SVG renderer based holder version would be great. Maybe doing it like jQuery and providing one file with canvas fallback and another without would be the way to go.
from holder.
Yes, Its true svg support is not complete is browsers but most of them supports very basic features of svg. Creating a rectangle and a textbox is supported AFAIK.
Your test result is just "wow". 12x speedup !!!
Maybe you can push your svg experiment in another branch ? I'm temporarily using this code in one of my project now.
from holder.
I'll push the SVG renderer as soon as the canvas
fallback is implemented for older browsers.
from holder.
Related Issues (20)
- Support Turbolinks 5 HOT 1
- (angular) binding to data-src HOT 3
- [Enhancement] Diagonal lines/border? HOT 8
- Support outline for rounded corners
- How to make images scaled down? HOT 1
- Image with no text HOT 2
- "size" attribute has no affect when using 100% width HOT 1
- Add support for specified aspect ratios. HOT 1
- holderjs not working inside tinymce [fiddle included] HOT 2
- 100% x 100% giving <svg> error in Chrome Canary Version 69.0.3494.0 (Official Build) canary (64-bit) HOT 1
- Could not set size lesser than certain value HOT 1
- holder.js does not work when the page renders twice in React HOT 14
- Refer to FontAwesome icons by their class names HOT 1
- high cpu usage HOT 2
- Issue with rendering in React using state variables HOT 2
- old dependency version prevent install with engine-strict=true HOT 3
- Need to replace `robloach/component-installer` HOT 3
- yoieh:patch-1
- Holderjs with Vite
- How can I use Holder.js in Next.js App Router?
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 holder.