Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

inferno-vnode-flags

Package Overview
Dependencies
Maintainers
5
Versions
223
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

inferno-vnode-flags

Provides an enum of all possible VNode Flags used when calling Inferno.createVNode

  • 1.6.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
126K
decreased by-6.44%
Maintainers
5
Weekly downloads
 
Created
Source

inferno-vnode-flags

Inferno VNode Flags is a small utility library for Inferno.

Usage of inferno-vnode-flags should be limited to assigning VNodeFlags when using Inferno.createVNode.

Install

npm install --save inferno-vnode-flags

Contents

  • VNodeFlags.Text
  • VNodeFlags.HtmlElement
  • VNodeFlags.ComponentClass
  • VNodeFlags.ComponentFunction
  • VNodeFlags.ComponentUnknown
  • VNodeFlags.HasKeyedChildren
  • VNodeFlags.HasNonKeyedChildren
  • VNodeFlags.SvgElement
  • VNodeFlags.MediaElement
  • VNodeFlags.InputElement
  • VNodeFlags.TextareaElement
  • VNodeFlags.SelectElement
  • VNodeFlags.Void

You can easily combine multiple flags, by using bitwise operators. A common use case is an element that has keyed children:

const flag = VNodeFlags.HtmlElement | VNodeFlags.HasKeyedChildren;

Example Usage

import Inferno from 'inferno';
import VNodeFlags from 'inferno-vnode-flags';

const vNode = Inferno.createVNode(VNodeFlags.Element, 'div', { className: 'example' }, 'Hello world!');

Inferno.render(vNode, container);

Keywords

FAQs

Package last updated on 05 Apr 2017

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc