node-html-to-jsx
The HTML to JSX Converter is a Node.js module that seamlessly transforms HTML markup into JSX syntax, ideal for your React projects.
Last updated 3 months ago by digelo .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install node-html-to-jsx 
SYNC missed versions from official npm registry.

Overview

Build Status Coverage Status License

This HTML to JSX Library provides functions to manipulate and transform HTML strings in JavaScript. It has utilities to wrap HTML content, close self-closing tags, convert event attributes to camel case, convert class attributes to className, remove HTML comments, indent HTML code, convert inline styles to objects, and validate HTML structure.

Contributors

Installation

To use the HTML Converter Library in your project, you can install it via npm:

npm install node-html-to-jsx

Usage

Import the library into your JavaScript file:

import convert from 'node-html-to-jsx';

Then, you can use the convert function to transform your HTML code:

const convertedHTML = convert('<div><p class="paragraph">Hello, world!</p></div>');

Demo

See DEMO

Note

This library is primarily designed for manipulating HTML strings in JavaScript environments, particularly for use with frameworks like React.

Contributing

We welcome contributions! Please see the CONTRIBUTING.md file for guidelines and instructions on how to get started.

License

This library is open-source and available under the MIT License.

Current Tags

  • 1.4.4                                ...           latest (3 months ago)

34 Versions

  • 1.4.4                                ...           3 months ago
  • 1.4.2                                ...           3 months ago
  • 1.4.1                                ...           3 months ago
  • 1.4.0                                ...           3 months ago
  • 1.3.7                                ...           5 months ago
  • 1.3.6                                ...           5 months ago
  • 1.3.4                                ...           5 months ago
  • 1.3.3                                ...           5 months ago
  • 1.3.2                                ...           10 months ago
  • 1.3.1                                ...           a year ago
  • 1.3.0                                ...           a year ago
  • 1.2.9                                ...           a year ago
  • 1.2.8                                ...           a year ago
  • 1.2.7                                ...           a year ago
  • 1.2.6                                ...           a year ago
  • 1.2.5                                ...           a year ago
  • 1.2.4                                ...           a year ago
  • 1.2.2                                ...           a year ago
  • 1.2.1                                ...           a year ago
  • 1.2.0                                ...           a year ago
  • 1.1.9                                ...           2 years ago
  • 1.1.8                                ...           2 years ago
  • 1.1.7                                ...           2 years ago
  • 1.1.6                                ...           2 years ago
  • 1.1.4                                ...           2 years ago
  • 1.1.3                                ...           2 years ago
  • 1.1.2                                ...           2 years ago
  • 1.1.1                                ...           2 years ago
  • 1.1.0                                ...           2 years ago
  • 1.0.9                                ...           2 years ago
  • 1.0.8                                ...           2 years ago
  • 1.0.7                                ...           2 years ago
  • 1.0.6                                ...           2 years ago
  • 1.0.5                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 34
Last Day 0
Last Week 34
Last Month 0
Dependencies (0)
None
Dev Dependencies (11)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |