open-index/open-npm huggingface dataset:
npm package: @james-wiens/react-components-icons
Description: React icon components using Material Design
Author: James Wiens
Latest version: 0.1.2

# React Components: Icons

> Material icons as react components

**TODO** documentation on usage

> https://jameswiens.dev

# ICON

> Acessible Material Icons
> Should be splitting this out and putting as a param


## Learn More
- https://css-tricks.com/accessible-svgs/
- https://medium.com/@aniboaz/animate-svg-4fa7dd00e860
- https://css-tricks.com/guide-svg-animations-smil/
- https://code.likeagirl.io/how-to-build-svg-code-and-svg-animations-7bb1e42f6ef
- https://stackoverflow.com/questions/46623645/react-reset-css-animation-in-progress
- https://www.thinkful.com/projects/bringing-svg-graphics-to-life-with-react-432/
- https://properdesign.rs/blog/2015/02/animating-svg-with-beginelement/
- https://css-tricks.com/restart-css-animation/
- https://medium.freecodecamp.org/how-to-build-animated-microinteractions-in-react-aab1cb9fe7c8
- http://plouc.github.io/react-svg-buttons/
- https://codesandbox.io/s/mqw8m78q1j
- https://codesandbox.io/s/nr87l4q6w0
- https://codesandbox.io/s/2wl104v5mr
- https://codesandbox.io/s/30y689wok5
- https://github.com/simple-icons/simple-icons/tree/develop/icons
- https://github.com/FortAwesome/react-fontawesome
- https://jakearchibald.github.io/svgomg/
### Related
- https://material-ui.com/components/material-icons/
- http://fortawesome.github.io/Font-Awesome/icons/
- https://github.com/Templarian/MaterialDesign/
- https://github.com/vaeum/react-material-icon-svg#readme
- https://material.io/resources/icons/
- https://github.com/dstaley/material-icons-svg
npm package: @james-wiens/react-components-image
Description: React image component with all of the bells & whistles
Author: James Wiens
Latest version: 0.1.3

# @james-wiens/react-components-image

> React image component with all of the bells & whistles
> Image loading is one of the most common impacts on performance.

- generates base64 small low quality placeholders on the server
- used `IntersectionObserver` to load images only when scrolled to
- update the `URL` to pass params based on the container elements size to fit the screen
- accessible and semantic, using picture and srcset (_it can also generate a media srcset list from a single src url string input_)
- on slow network, it will not automatically download the images, instead it will show click to download with the respective icon
- if the loading errors, it show the error icon and text accordingly
- when the user goes offline, if it is not already downloaded, it will show the offline icon until they go online again
- when loading, loading icon shows overlayed on the image
- on the server, measures the size of the image to get the width and height (as required by amp, and html built in lazy loading attribute) and puts into a rehydratable ssr script
- support for AMP
- has support for older browsers using an XHR request that is cancellable and can be configured with props for a max timeout before making it click to download [though this is excluded by default since it's a fair bit of code size and only needed for older browsers]
- material icons for offline, download, warning, loading, etc (available in the `ImageComponentWithDefaults`, or as a render prop)
- runs puppeteer to determine which images are above the fold, saves to JSON, then that JSON is used on the server to render the image always above the fold (show the src) [this part is not finished yet but WIP]
- caching & persistence using OneStorage (universal interface for storage on server and browser using file system, local storage, indexdb, in memory, and any additional adapters) [as it's own package, optional, comes with `ImageComponentWithDefaults`]
- custom minimal ssr (with hooks and context) [as it's own package, optional, comes with `ImageComponentWithDefaults`]

- all typescript typings
- storybook
- gzip size ~4kb, 75% test coverage

> https://jameswiens.dev