e-oj / Magic-Grid

A simple, lightweight Javascript library for dynamic grid layouts.
https://www.npmjs.com/package/magic-grid
MIT License
3.14k stars 144 forks source link

Add ability to select items via config #69

Open urbantrout opened 4 months ago

urbantrout commented 4 months ago

rename items to size (which is used internally) use items as option to select nodes (useful if items are not direct descendants)

this change makes it possible to use magic-grid with custom elements (web components)

e-oj commented 3 months ago

Seems interesting but I don't understand the use case. Currently the library allows you to specify a container so that you don't have to specify the children. This PR would be allowing users to specify the children so they don't have to specify the container? What does this achieve?