🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

simple-tree-component

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

simple-tree-component

A simple to use ui-tree javascript component.

Source
npmnpm
Version
1.2.0
Version published
Weekly downloads
15
-16.67%
Maintainers
1
Weekly downloads
 
Created
Source

Simple Tree Component

build codecov NPM

This pure JavaScript component comes without any dependencies and is targeted to modern browsers. Full TypeScript support is available.

Installation

Install with NPM:

npm install simple-tree-component

TypeScript definitions are included in the npm package.

Usage

import simpleTree from "simple-tree-component";

const instance = simpleTree(".root-1", "singleSelectDropdown", {
    nodes: [
        {
            label: "Parent 1",
            value: "p1",
            children: [
                {
                    label: "Parent 1 - Child 1",
                    value: "p1c1"
                },
                {
                    label: "Parent 1 - Child 2",
                    value: "p1c2"
                }
            ]
        }
    ]
});

instance.setReadOnly(true);

You can find more documentation here.

Contributing

License

Changelog

Blog post

https://dev.to/ckotzbauer/announcing-the-simple-tree-component-46nd

Keywords

js

FAQs

Package last updated on 08 Oct 2021

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