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 🙏

© 2026 – Pkg Stats / Ryan Hefner

flyql-react

v1.2.0

Published

React editor components for FlyQL query language

Readme

flyql-react

React editor components for FlyQL — a schema-driven query input with autocomplete, syntax highlighting, and keyboard navigation, plus a dedicated columns expression editor.

Installation

npm install flyql-react
# or
pnpm add flyql-react

flyql-react depends on the flyql core package and is automatically installed alongside it. React 18 or 19 is required as a peer dependency:

npm install react react-dom

Requires Node.js 18+.

flyql-react ships untranspiled JSX sources (mirroring flyql-vue, which ships raw .vue SFCs). Vite handles this out of the box; with webpack/Babel setups, make sure your JSX transform also covers node_modules/flyql-react (it is excluded by default).

Quick Start

Query editor

import { useState } from 'react'
import { FlyqlEditor, ColumnSchema } from 'flyql-react'
import 'flyql-react/flyql.css'

const columns = ColumnSchema.fromPlainObject({
    status: { type: 'number', suggest: true },
    level: { type: 'enum', suggest: true, autocomplete: true, values: ['debug', 'info', 'error'] },
    service: { type: 'string', suggest: true, autocomplete: true },
    host: { type: 'string', suggest: true },
})

function App() {
    const [query, setQuery] = useState('')

    return (
        <FlyqlEditor
            value={query}
            onChange={setQuery}
            columns={columns}
            placeholder="Type a FlyQL query..."
            onSubmit={() => console.log('Query:', query)}
        />
    )
}

Columns expression editor

import { useState } from 'react'
import { FlyqlColumns, ColumnSchema } from 'flyql-react'
import 'flyql-react/flyql.css'

const columns = ColumnSchema.fromPlainObject({
    message: { type: 'string', suggest: true },
    status: { type: 'number', suggest: true },
    host: { type: 'string', suggest: true },
})

function App() {
    const [expr, setExpr] = useState('')

    return (
        <FlyqlColumns
            value={expr}
            onChange={setExpr}
            columns={columns}
            capabilities={{ transformers: true }}
            placeholder="message, status|upper, host as h"
        />
    )
}

What's in the box

| Export | Description | |---|---| | FlyqlEditor | React query editor component with autocomplete and syntax highlighting | | FlyqlColumns | React column expression editor component | | EditorEngine | Framework-agnostic editor engine (re-exported from flyql/editor) | | ColumnsEngine | Framework-agnostic columns engine (re-exported from flyql/editor) | | ColumnSchema, Column | Schema helpers (re-exported from flyql/core) | | flyql-react/flyql.css | Theme variables, suggestion panel styles, and token highlighting |

Component API

FlyqlEditor props: value, onChange, columns, parameters, onAutocomplete, onKeyDiscovery, placeholder, autofocus, debug, debounceMs (default 150), dark, registry, label, plus callbacks onSubmit, onParseError, onFocus, onBlur, onDiagnostics and an icon render prop. A ref exposes focus(), blur(), getQueryStatus(), and flushDiagnostics().

FlyqlColumns props: value, onChange, columns, capabilities, onKeyDiscovery, placeholder, autofocus, debug, dark, registry, rendererRegistry, label, icon, plus callbacks onSubmit, onParseError, onParsedChange, onFocus, onBlur, onDiagnostics and a loading render prop. A ref additionally exposes getParsedColumns().

label and icon share the slot on the left of the field, ahead of the query text. label takes a string or any node; icon takes a node, a render function, or false to drop the built-in glyph. Clicking either focuses the input, and a text label becomes the input's accessible name. The label renders in the UI font (--flyql-font-family), baseline-corrected to sit on the query text's baseline.

<FlyqlEditor value={query} onChange={setQuery} label="Filter" icon={false} />

capabilities is read once when the component mounts (it configures the underlying engine's parser; the same is true of the Vue component). To change capabilities at runtime, remount the component with a key.

Theming

The editor uses CSS custom properties (--flyql-* variables) for all visual styling. A built-in dark prop toggles the dark theme, and any variable can be overridden in your CSS to match your application's design.

<FlyqlEditor value={query} onChange={setQuery} columns={columns} dark={isDark} />

See the theming documentation for the full list of variables and customization patterns.

Documentation

Full reference: docs.flyql.dev/editor

License

MIT