/    Sign up×
Community /Pin to ProfileBookmark

HTML table vs Grid vs HTML Table Grid (hybrid)?

I have Googled this many time, but found no good answers. Regarding how easy it is to set up, fill with data, maintain and if there is any speed differences. I stumbled on an example of a hybrid “HTML Table Grid”.

Anybody used this hybrid table? Any preferences? Why?

to post a comment
CSSHTMLJavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@JMRKERJan 14.2022 — Do you have some code or a link to what you have looked at?
Copy linkTweet thisAlerts:
@SempervivumJan 14.2022 — @sibert#1641516
>Regarding how easy it is to set up, fill with data, maintain and if there is any speed differences.

IMO none of these is relevant for the decision whether to use a table or grid layout. Instead it depends on the type of data and semantics.

A typical example for a table is an address list: The header contains "first name", "last name", "ZIP", "city", etc. And there is a relationship between the headline and the values below: E. g. below "first name" there are the first names of the individual persons. And in one row all the data belongs to the same person.

On the other hand in a grid there is no such relation, all cells are independent (though in some special case there may be a relation but this is not necessary). A typical example is an image gallery.
Copy linkTweet thisAlerts:
@sibertauthorJan 19.2022 — > @JMRKER#1641551 Do you have some code or a link to what you have looked at?

I found this. A table formatted as a grid. Anybody used this and can tell if this hybrid is a way to go?

https://codepen.io/adam-lynch/pen/XwKWdG
Copy linkTweet thisAlerts:
@SempervivumJan 19.2022 — Cool stuff! I was a bit surprised that this works as usually the grid items are direct children of the grid container. However, this example is proving that when applying `display: grid;</C> to <C>table</C> the <C>grid-template-columns</C> is affecting the table cells. This might be useful as one is able to use features like <C>minmax` which are not available for a table.
×

Success!

Help @sibert spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 4.23,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...