You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- ➡️ Render images horizontally or vertically in a grid.
41
45
- ⚡ Built-in virtualization for improved performance.
42
46
- 🖼️ Load thousands of images without worrying about performance.
43
47
- 🎛️ UI controls for adjusting image sizes.
44
-
- ➡️ Render images horizontally or vertically in a grid.
45
48
- 💡 Resizable Grid
49
+
- 📦 Lightweight (7kb gzipped)
46
50
- 💪 Built with typescript.
47
51
- 💡 Easy-to-understand API and a completely configurable React component.
48
52
@@ -52,11 +56,11 @@
52
56
53
57
## 💭 How it works <aname = "working"></a>
54
58
55
-
`react-visual-grid` works with the absolute minimum of properties to determine the optimal method to render images. All that is required is to specify the picture sizes desired, and the component will automatically determine the optimum approach to render the images.
59
+
`react-visual-grid` works with the absolute minimum of properties to determine the optimal method to render images. Specify the desired picture sizes and the layout, the component will automatically determine the optimum approach to rendering the images.
56
60
57
-
Because virtualization is built in, you won't have to worry about performance.
61
+
Comes with two different layouts (horizontal and vertical) for rendering images. The in-built virtualization ensures that the component renders only the images that are visible on the screen. This ensures that the component is able to render thousands of images without any performance issues.
58
62
59
-
The component handles loading 5k+ photos with ease in the example. Both horizontal and vertical virtualization are supported.
63
+
Resize the grid or go full screen, and the component will automatically adjust the image sizes to fit the new grid size.
60
64
61
65
## ⚙️ Installation <aname = "installation"></a>
62
66
@@ -66,6 +70,8 @@ You can install `react-visual-grid` using npm or yarn.
66
70
npm install react-visual-grid
67
71
```
68
72
73
+
or
74
+
69
75
```bash
70
76
yarn add react-visual-grid
71
77
```
@@ -144,9 +150,9 @@ const App = () => {
144
150
145
151
## ImageSizes
146
152
147
-
`react-visual-grid` currently supports 3 zoom levels for the images. The default zoom level is 2x. The zoom levels can be configured using the `imageSizes` prop.
153
+
`react-visual-grid` currently supports 3 zoom levels and the default level is 2x. The zoom levels can be configured using the `imageSizes` prop.
148
154
149
-
The component comes with a default configuration for the image sizes. The default configuration is as follows:
155
+
The component comes with a default configuration for the image sizes.
150
156
151
157
```js
152
158
exportconstdefaultImageSizes= {
@@ -175,6 +181,7 @@ Here is the list of all the colors that can be customized:
0 commit comments