
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@qitplus/guijson
Advanced tools
TypeScript types for a GUI JSON schema inspired by GeoJSON.
guijson provides a typed way to describe UI trees as JSON objects. Like GeoJSON, every object is identified by a type field, which makes the schema easy to serialize, inspect, validate, and render in your own runtime.
npm install guijson
GuiJson union for all supported GUI JSON nodesContainer, Image, Text, Button, TextInput, Switch, Column, Row, and StackReference and ReferenceCollectionComponentCollection type for storing reusable component definitionsid, style, and properties shapesAction types for events such as onPress and onChangeimport type { GuiJson } from 'guijson';
type Style = {
padding?: number;
gap?: number;
fontSize?: number;
};
type Props = {
testId?: string;
};
const screen: GuiJson<string, Style, Props> = {
type: 'Column',
id: 'home',
style: { padding: 24, gap: 12 },
properties: { testId: 'home-screen' },
children: [
{
type: 'Text',
text: 'Hello, GuiJson',
style: { fontSize: 20 },
},
{
type: 'TextInput',
value: '',
placeholder: 'Search',
onChange: ['setSearch'],
},
{
type: 'Button',
onPress: ['navigate', 'details'],
child: {
type: 'Text',
text: 'Open details',
},
},
],
};
Every GUI JSON object includes:
type: the node discriminatorid?: an optional string or number identifierEvery component may also include:
class?: a class-like labelstyle?: any style shape you define through genericsproperties?: any custom metadata shape you define through genericsContainerImageTextButtonTextInputSwitchColumnRowStackComponentCollectionReferenceReferenceCollectionInteractive components use the Action tuple type:
type Action<K extends string = string, A extends Array<any> = Array<any>> =
[call: K, ...arguments: A];
That means event handlers can stay fully serializable:
const action = ['navigate', 'settings'] as const;
Use references if you want reusable or normalized component definitions.
import type { ComponentCollection, Reference } from 'guijson';
const components: ComponentCollection = {
type: 'ComponentCollection',
components: [
{ id: 'title', type: 'Text', text: 'Dashboard' },
{ id: 'hero', type: 'Image', src: '/hero.png', alt: 'Hero image' },
],
};
const titleRef: Reference = {
type: 'Reference',
reference: 'title',
};
GuiJSON namespace for non-module usage.MIT
FAQs
A package for using the guijson format
We found that @qitplus/guijson demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.