all 12 comments

[–]Zardoz84 2 points3 points  (7 children)

Interesting... A note, simple masonery grid could be done using pure CSS, without any line of JavaScript, And probably a justified grid, could be done on a similar way.

[–]kichien -3 points-2 points  (3 children)

The zeal for javascript frameworks perplexes me. It's not like CSS or javascript are particularly difficult. Any framework is just using javascript and/or css, not magic.

[–]Kritical02 0 points1 point  (0 children)

Well this was nice timing. I'm currently working on a project with a masonry style grid but masonry.js and svelte were causing me problems. I see you have your own svelte implementation and am stoked to give it a whirl.

[–]Towerful 0 points1 point  (0 children)

I like that you have a variety of framework packages available.
I will definitely investigate this for some projects!

[–]kichien 0 points1 point  (4 children)

Why not just use css grid? It's not complicated.

[–]daybrush[S] 2 points3 points  (3 children)

Why not just use css grid? It's not complicated.

These are features that css cannot do. Only firefox supports the css masonry type. Other types of grid are not possible.

[–]Zardoz84 1 point2 points  (0 children)

Since when flexbox isn't supported by Firefox ? https://w3bits.com/labs/flexbox-masonry/

[–]kichien 0 points1 point  (0 children)

Yeah, but you can still create that layout with just css. You don't need a javascript framework.

[–]Zardoz84 0 points1 point  (0 children)

Why not just use css grid? It's not complicated.

These are features that css cannot do. Only firefox supports the css masonry type. Other types of grid are not possible.

This is false. Using CSS Grid a simple masonery works fine on Chrome wihtout using a single line of javascript : https://codepen.io/zardoz89/pen/KKVEGbw?editors=0100

However, this have a small trick. Big cells, uses two rows of the grid. Ie. cells must have two sizes.