Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.

Commit 5fe6f7e

Browse files
committed
docs: updated readme
1 parent 73b8571 commit 5fe6f7e

File tree

3 files changed

+80
-21
lines changed

3 files changed

+80
-21
lines changed

README.md

Lines changed: 63 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,36 @@
1-
# react-native-better-image
1+
<div align="center">
22

3-
A better image component for react-native with fallback images &amp; progressive loading support
3+
# React Native Better Image
44

5-
## Note
5+
A better image component for react-native with fallback images & progressive loading support
66

7-
The library is ready for use but the documentation is WIP 👷🏽‍♂️
7+
Built on top of `View`, `Image` & `Animated` components
8+
9+
[![Build Status][build-badge]][build]
10+
[![Maintainability][maintainability-badge]][maintainability-url]
11+
[![Test Coverage][coverage-badge]][coverage-url]
12+
13+
[![Version][version-badge]][package]
14+
[![Downloads][downloads-badge]][npmtrends]
15+
[![Bundlephobia][bundle-phobia-badge]][bundle-phobia]
16+
17+
[![Star on GitHub][github-star-badge]][github-star]
18+
[![Watch on GitHub][github-watch-badge]][github-watch]
19+
[![Twitter Follow][twitter-badge]][twitter]
20+
21+
[![Storybook][storybook-badge]][website] [![Chromatic][chromatic-badge]][chromatic]
22+
23+
### Compatible with Expo & React Native Web 🚀
24+
25+
### PRs Welcome 👍✨
26+
27+
</div>
28+
29+
- 📦 [Installation](#installation)
30+
- ℹ️ [Usage](#usage)
31+
- 📃 [Documentation][website]
32+
-[Motivation](#motivation)
33+
- 📱 [Example App][expo]
834

935
## Installation
1036

@@ -38,10 +64,43 @@ import BetterImage from 'react-native-better-image';
3864
/>
3965
```
4066

67+
## Motivation
68+
69+
React Native only includes a basic image component. I used to try solutions like [react-native-fast-image](https://github.com/DylanVann/react-native-fast-image) but none actually worked for the two of my most important issues:
70+
71+
- Lack of a fallback placeholder
72+
- Progressive image loading (especially for banners & cover images)
73+
74+
This library solves two of these important issues by providing a fallbackSource & a thumbnailSource prop. If you need more features, feel free to raise an issue or send a PR ✨ I'd be happy to help 👍
75+
4176
## Contributing
4277

4378
See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow.
4479

4580
## License
4681

4782
MIT
83+
84+
[build]: https://github.com/react-native-toolkit/react-native-better-image/actions
85+
[build-badge]: https://github.com/react-native-toolkit/react-native-better-image/workflows/build/badge.svg
86+
[coverage-badge]: https://api.codeclimate.com/v1/badges/acf5243d130542dde7c9/test_coverage
87+
[coverage-url]: https://codeclimate.com/github/react-native-toolkit/react-native-better-image/test_coverage
88+
[maintainability-badge]: https://api.codeclimate.com/v1/badges/acf5243d130542dde7c9/maintainability
89+
[maintainability-url]: https://codeclimate.com/github/react-native-toolkit/react-native-better-image/maintainability
90+
[bundle-phobia-badge]: https://badgen.net/bundlephobia/minzip/react-native-better-image
91+
[bundle-phobia]: https://bundlephobia.com/result?p=react-native-better-image
92+
[downloads-badge]: https://img.shields.io/npm/dm/react-native-better-image.svg
93+
[npmtrends]: http://www.npmtrends.com/react-native-better-image
94+
[package]: https://www.npmjs.com/package/react-native-better-image
95+
[version-badge]: https://img.shields.io/npm/v/react-native-better-image.svg
96+
[twitter]: https://twitter.com/dani_akash_
97+
[twitter-badge]: https://img.shields.io/twitter/follow/dani_akash_?style=social
98+
[github-watch-badge]: https://img.shields.io/github/watchers/react-native-toolkit/react-native-better-image.svg?style=social
99+
[github-watch]: https://github.com/react-native-toolkit/react-native-better-image/watchers
100+
[github-star-badge]: https://img.shields.io/github/stars/react-native-toolkit/react-native-better-image.svg?style=social
101+
[github-star]: https://github.com/react-native-toolkit/react-native-better-image/stargazers
102+
[storybook-badge]: https://cdn.jsdelivr.net/gh/storybookjs/brand@master/badge/badge-storybook.svg
103+
[website]: https://betterimage.netlify.app
104+
[chromatic-badge]: https://img.shields.io/badge/-chromatic-%23fc521f
105+
[chromatic]: https://chromatic.com/library?appId=5f5078c6fe7d0c0022c82f06&branch=master
106+
[expo]: https://expo.io/@daniakash/react-native-better-image-example

example/src/stories/GettingStarted.stories.mdx

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -18,22 +18,6 @@ A better image component for react-native with fallback images & progressive loa
1818

1919
Built on top of `View`, `Image` & `Animated` components
2020

21-
### Compatible with Expo & React Native Web 🚀
22-
23-
### PRs Welcome 👍✨
24-
25-
[![Build Status][build-badge]][build]
26-
[![Maintainability][maintainability-badge]][maintainability-url]
27-
[![Test Coverage][coverage-badge]][coverage-url]
28-
29-
[![Version][version-badge]][package]
30-
[![Downloads][downloads-badge]][npmtrends]
31-
[![Bundlephobia][bundle-phobia-badge]][bundle-phobia]
32-
33-
[![Star on GitHub][github-star-badge]][github-star]
34-
[![Watch on GitHub][github-watch-badge]][github-watch]
35-
[![Twitter Follow][twitter-badge]][twitter]
36-
3721
<div style={{ display: 'flex', flexDirection: 'row' }}>
3822
<BetterImage
3923
source={{
@@ -76,6 +60,22 @@ Built on top of `View`, `Image` & `Animated` components
7660
/>
7761
</div>
7862

63+
### Compatible with Expo & React Native Web 🚀
64+
65+
### PRs Welcome 👍✨
66+
67+
[![Build Status][build-badge]][build]
68+
[![Maintainability][maintainability-badge]][maintainability-url]
69+
[![Test Coverage][coverage-badge]][coverage-url]
70+
71+
[![Version][version-badge]][package]
72+
[![Downloads][downloads-badge]][npmtrends]
73+
[![Bundlephobia][bundle-phobia-badge]][bundle-phobia]
74+
75+
[![Star on GitHub][github-star-badge]][github-star]
76+
[![Watch on GitHub][github-watch-badge]][github-watch]
77+
[![Twitter Follow][twitter-badge]][twitter]
78+
7979
```jsx
8080
import BetterImage from 'react-native-better-image';
8181

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"bugs": {
4141
"url": "https://github.com/react-native-toolkit/react-native-better-image/issues"
4242
},
43-
"homepage": "https://github.com/react-native-toolkit/react-native-better-image#readme",
43+
"homepage": "https://betterimage.netlify.app",
4444
"devDependencies": {
4545
"@commitlint/config-conventional": "^8.3.4",
4646
"@react-native-community/bob": "^0.16.2",

0 commit comments

Comments
 (0)