Socket
Socket
Sign inDemoInstall

remark-breaks

Package Overview
Dependencies
Maintainers
2
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remark-breaks

remark plugin to add break support, without needing spaces


Version published
Weekly downloads
271K
increased by6.21%
Maintainers
2
Weekly downloads
 
Created

What is remark-breaks?

The remark-breaks package is a plugin for the remark markdown processor that automatically converts hard line breaks in markdown text into HTML `<br>` tags. This can be particularly useful for ensuring that line breaks in markdown are preserved in the rendered HTML output.

What are remark-breaks's main functionalities?

Automatic Line Break Conversion

This feature allows you to automatically convert hard line breaks in markdown text into HTML `<br>` tags. In the example, the markdown text 'Hello\nWorld' will be converted to 'Hello<br>World' in the HTML output.

const remark = require('remark');
const breaks = require('remark-breaks');

const markdown = 'Hello\nWorld';

remark()
  .use(breaks)
  .process(markdown, function (err, file) {
    if (err) throw err;
    console.log(String(file));
  });

Other packages similar to remark-breaks

Keywords

FAQs

Package last updated on 22 Sep 2023

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