gl-react-blurhash
TypeScript icon, indicating that this package has built-in type declarations

2.0.0 • Public • Published

gl-react-blurhash runs with expo

Universal gl-react module that implements BlurHash in OpenGL.

Installation

Expo

Add the following dependencies:

expo add gl-react gl-react-expo expo-gl buffer gl-react-blurhash

React Native

First setup react-native-unimodules, then add the following dependencies:

yarn add gl-react gl-react-native buffer gl-react-blurhash

Usage

import React from 'react';
import { Surface } from 'gl-react-expo'; // 'gl-react-native' for React Native
import { Blurhash } from 'gl-react-blurhash';

export default function App {
    return (
        <Surface style={{ width: 300, height: 200 }}>
            <Blurhash hash="LPKA$w{H_c05b{Nqwbx^grotMnNf" />
        </Surface>
    );
}

Example

See example subfolder for a full example. This example is also available on snack.expo.io.

Readme

Keywords

Package Sidebar

Install

npm i gl-react-blurhash

Weekly Downloads

0

Version

2.0.0

License

MIT

Unpacked Size

29.9 kB

Total Files

34

Last publish

Collaborators

  • schiller-manuel