

Astro LightGallery is the native Astro component for lightGallery. lightGallery is a feature-rich, modular JavaScript gallery plugin for building beautiful image and video galleries for the web and the mobile
It includes some layouts to ease integration of lightgallery.

Get the latest version from NPM:
$ npm install astro-lightgallery
Astro-lightGallery is released under the MIT license.
Astro-lightGallery is using lightGallery. lightGallery is a free and open-source library, however, if you are using the library for business, commercial sites, projects, and applications, choose the commercial license to keep your source proprietary, to yourself. Please refer to the lightGallery license page
Here is a simple example that is using the default layout (adaptive). Layout can be customized, by defining your own classes definition (as for example adding effects on hover)
---
import { LightGallery } from 'astro-lightgallery'
---
<LightGallery
layout={{
imgs: [
{ src: "/img01.jpg", },
{ src: "/img02.jpg", },
...
]
}}
options={{
thumbnail: true,
}}
/>
Layout can be customized. But we may also want to use astro-lightgallery without layouts, and use native lightgallery scheme.
Please check the online doc for a fullset of examples, including navigation and thumbnails.
Full code is provided.