npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ruio

v0.9.1

Published

A React developer tool for dynamically applying border styles to elements.

Downloads

77

Readme

⚠️ Disclaimer: Ruio is currently in an unstable state and is still under active development. Features, UI, and behaviors may change frequently. Use it with caution (for now :D).

ruio

ruio (short for React UI Outliner) is a developer tool designed for React applications that allows you to dynamically apply real-time border styles to elements at the click of a button. Inspired by the Google Chrome Inspect Tool, Ruio provides instant visual feedback to help developers identify layout issues and optimize the structure of their applications. The tool is optimized for performance and scalability, offering a seamless integration experience in any React project.

npm license

Features

  • Dynamic Border Styling: Visualize borders on any element within your React app.
  • Element Selection Mode: Mimics the hover effect of Chrome DevTools to highlight elements on the page.
  • Click-to-Select: Make any element the new root with a click.
  • Toggle Logic: Enable and disable border styling on the fly as well as memory of selected root element.
  • Reset Functionality: Automatically clear all applied border styles.
  • Highly Configurable: Works with different project structures and exists on top of any existing architectures.

Table of Contents

Installation

You can install Ruio via npm:

npm install ruio

Usage

To get started with Ruio, wrap your application in the RuioContextProvider:

// App.tsx
import RuioContextProvider from 'ruio';

function App() {
	return (
		<RuioContextProvider>{/* Your App Components Here */}</RuioContextProvider>
	);
}

export default App;

As long as youre in a development environment the ruio toggle icon will render. This button allows you to enable or disable the border visualization mode.

Now, once the toggle button is clicked, you’ll be able to hover over elements in your app's DOM tree and see real-time UI insights being applied.

Configuration

Ruio is slated for a configurative UI soon! Check back for new customized options such as:

  • Outline UI depth selection.
    • Crawl deeper down the DOM tree
    • Option to crawl up the DOM tree
    • Simultaneously crawl the DOM upwards and downwards
  • Color theming
  • Keyboard macros for accessibility (+ key binding)

Element Exclusion

Applying ruio-exclude class to elements that you don't want to be considered for ruio's UI styling (inclusive). Any descendant of a component with the ruio-exclude class will also be excluded from ruio styling.

<div className="ruio-exclude">
	{/* Content that shouldn't be affected by Ruio */}
</div>

Development

To start developing Ruio locally:

  1. Clone the repository:
git clone https://github.com/gary-rivera/ruio.git
  1. Install dependencies:
npm install
  1. Start the development server:
npm run dev
  1. You can also run tests to ensure everything is working correctly:
npm run test

Trying it out

You can test ruio with the example React project:

react-redux-realworld-example-app repo

Note: since the referenced project is no longer maintained, you may have to use the --force flag to override dependency conflicts

License

ruio is licensed under the MIT License. See the LICENSE file for more details.