New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@hoook/use-file

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hoook/use-file

This is true use file hook for browser, you don't have to need a input element to handle event, just focus on your UI component.

latest
Source
npmnpm
Version
0.1.0
Version published
Weekly downloads
1
-50%
Maintainers
1
Weekly downloads
 
Created
Source

React use file hook

This is true use file hook for browser, you don't have to need a input element to handle event, just focus on your UI component.

Usage

import React from 'react';
import { useFile } from '@hoook/use-file';

export default function() {
  const [trigger, content] = useFile();

  return (
    <div>
      <div onClick={() => trigger()}>Whatever your trigger is</div>
      <p>{content}</p>
    </div>
  );
}

Keywords

react hook

FAQs

Package last updated on 19 May 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