Socket
Book a DemoInstallSign in
Socket

gl-react-blurhash

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gl-react-blurhash

Universal gl-react module that implements BlurHash in OpenGL

latest
Source
npmnpm
Version
2.0.0
Version published
Maintainers
1
Created
Source

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.

Keywords

blurhash

FAQs

Package last updated on 03 Jul 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts