Skip to content

Commit ac27266

Browse files
committed
merged README.md from master
2 parents 2b479f9 + fa7280c commit ac27266

File tree

1 file changed

+6
-61
lines changed

1 file changed

+6
-61
lines changed

README.md

Lines changed: 6 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<h1 align="center">
22
<img width="32" alt="icon" src="https://raw.githubusercontent.com/GregoryNative/react-native-gl-image-filters/docusaurus/website/static/img/favicon_32.ico">
3+
react-native-gl-image-filters
34
</h1>
45

56
<p align="center">
@@ -15,6 +16,9 @@
1516
<a href="https://snack.expo.io/@gregoryrn/expo-gregorynative-react-native-gl-image-filters">
1617
<img src="https://badgen.net/badge/expo/snack/blue?icon=https://symbols.getvecta.com/stencil_79/82_expo-icon.11a3983570.svg" alt="Expo snack." />
1718
</a>
19+
<a href="https://stackblitz.com/edit/react-native-gl-image-filters-web-example">
20+
<img src="https://badgen.net/badge/web/blitz/purple?icon=bitcoin-lightning" alt="Expo snack." />
21+
</a>
1822
</p>
1923

2024
[](https://badgen.net/badge/expo/snack/blue?icon=https://symbols.getvecta.com/stencil_79/82_expo-icon.11a3983570.svg)
@@ -305,71 +309,12 @@ yarn add gl-react-dom@^4.0.1
305309
## Usage
306310

307311
### Usage with React Native
308-
```javascript
309-
import React, { Component } from 'react';
310-
import {
311-
StyleSheet,
312-
Text,
313-
View,
314-
Button
315-
} from 'react-native';
316-
import { Surface } from 'gl-react-native';
317-
import ImageFilters from 'react-native-gl-image-filters';
318-
319-
export default class App extends Component {
320-
save = async () => {
321-
if (!this.image) return;
322-
323-
const result = await this.image.glView.capture();
324-
console.warn(result);
325-
};
326-
327-
render() {
328-
return (
329-
<View style={styles.container}>
330-
<Text style={styles.welcome}>
331-
Welcome to React Native Image Filters!
332-
</Text>
333-
<Surface
334-
width={300}
335-
height={300}
336-
ref={ref => (this.image = ref)}
337-
>
338-
<ImageFilters
339-
width={300}
340-
height={300}
341-
temperature={10000}
342-
sharpen={1}
343-
hue={0.5}
344-
blur={0.5}
345-
>
346-
{{ uri: 'https://i.imgur.com/5EOyTDQ.jpg' }}
347-
</ImageFilters>
348-
</Surface>
349-
<Button title="Save" onPress={this.save} />
350-
</View>
351-
);
352-
}
353-
}
354-
355-
const styles = StyleSheet.create({
356-
container: {
357-
flex: 1,
358-
justifyContent: 'center',
359-
alignItems: 'center',
360-
backgroundColor: '#F5FCFF',
361-
},
362-
welcome: {
363-
fontSize: 20,
364-
textAlign: 'center',
365-
margin: 10,
366-
}
367-
});
368-
```
312+
Example here: [examples/react-native](https://github.com/GregoryNative/react-native-gl-image-filters/tree/master/examples/react-native)
369313

370314
### Usage with Expo
371315
Snack: https://snack.expo.io/@gregoryrn/expo-gregorynative-react-native-gl-image-filters <br>
372316
Example here: [examples/expo](https://github.com/GregoryNative/react-native-gl-image-filters/tree/master/examples/expo)
373317

374318
### Usage with React web
319+
Blitz: https://stackblitz.com/edit/react-native-gl-image-filters-web-example <br>
375320
Example here: [examples/web](https://github.com/GregoryNative/react-native-gl-image-filters/tree/master/examples/web)

0 commit comments

Comments
 (0)