🚀 DAY 5 OF LAUNCH WEEK: Introducing Socket Firewall Enterprise.Learn more →
Socket
Book a DemoInstallSign in
Socket

jsx-md

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsx-md

Generate markdown files with a React-like syntax.

latest
Source
npmnpm
Version
4.0.1
Version published
Maintainers
1
Created
Source

jsx-md

npm version downloads open issues build status codecov dependency status devDependency status

Generate markdown files with a React-like syntax.

Usage

// We need to tell the JSX transpiler that in this file,
// instead of React we use the custom createElement and Fragment
// functions from jsx-md
/* @jsx MD */
/* @jsxFrag Fragment */
import MD, { Component, Fragment, Heading, LineBreak, render, Text } from "jsx-md";
import { writeFileSync } from "fs";
import pkg from "./package.json";

const Readme: Component = () => (
  <>
    <Heading level={1}>{pkg.name}</Heading>
    <Text>{pkg.description}</Text>
    <LineBreak />
  </>
);

async function writeReadme() {
  writeFileSync("README.md", await render(<Readme />));
}

void writeReadme();

Documentation

There's a documentation of all elements you can use.

Keywords

Markdown

FAQs

Package last updated on 15 Oct 2020

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