Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@riseact/app-portal

Package Overview
Dependencies
Maintainers
0
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@riseact/app-portal

React components and utils to communicate with Riseact from your frontend

latest
Source
npmnpm
Version
1.0.0
Version published
Weekly downloads
9
-50%
Maintainers
0
Weekly downloads
 
Created
Source

@riseact/app-portal

React components and utils to communicate with Riseact from your frontend

Installation

npm install @riseact/app-portal yarn add @riseact/app-portal

Usage

import { usePortalToast } from "@riseact/app-portal"


function ToastButton() {
    const toast = usePortalToast()

    function handleClick = () => {
        toast.success("This is rendered by Riseact!")
    }

    return (
        <button onClick={handleClick}>
            Click me
        </button>
    )
}
import { NavbarMenu } from "@riseact/app-portal"
import { useNavigate } from "react-router-dom"


function Page({ children }) {
    const navigate = useNavigate()

    return (
        <div>
            <NavbarMenu>
                <MenuItem onClick={() => navigate("/home")}>Home</MenuItem>
                <MenuItem onClick={() => navigate("/about")}>About</MenuItem>
            </NavbarMenu>   
            {children}
        <div>
    )
}

License

MIT © Metadonors

Keywords

riseact

FAQs

Package last updated on 17 Jul 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