Socket
Book a DemoInstallSign in
Socket

use-midnight

Package Overview
Dependencies
Maintainers
0
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

use-midnight

A React hook to use Midnight in the browser

0.1.0
latest
npmnpm
Version published
Weekly downloads
0
-100%
Maintainers
0
Weekly downloads
 
Created
Source

use-midnight

A React hook to use Midnight in the browser

NPM JavaScript Style Guide

Install

npm install use-midnight

Usage

import React from "react";

import { useMidnight, MidnightButton } from "use-midnight";
import type { MidnightAPI } from "use-midnight";

function App() {
  const subscribe = (mn: MidnightAPI) => {
    console.log(md);
  };

  return <MidnightButton subscribe={subscribe} />;
}

The hook has 2 exports:
1- a useMidnight function that performs different checks and returns values injected by the Lace wallet into the browser
2- a MidnightButton with a customizable appearance that shows the status of the dapp and user connection to the Lace wallet

License

MIT © claudebarde

Keywords

React

FAQs

Package last updated on 10 Dec 2024

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

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.