🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis
Socket
Book a DemoInstallSign in
Socket

@wordpress/autop

Package Overview
Dependencies
Maintainers
6
Versions
201
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wordpress/autop

WordPress's automatic paragraph functions `autop` and `removep`

Source
npmnpm
Version
1.0.6
Version published
Weekly downloads
112K
14.17%
Maintainers
6
Weekly downloads
 
Created
Source

@wordpress/autop

JavaScript port of WordPress's automatic paragraph function autop and the removep reverse behavior.

Installation

Install the module

npm install @wordpress/autop --save

Usage

Import the desired function(s) from @wordpress/autop:

import { autop, removep } from '@wordpress/autop';

autop( 'my text' );
// "<p>my text</p>"

removep( '<p>my text</p>' );
// "my text"

API Usage

  • autop( text: string ): string
  • removep( text: string ): string



Code is Poetry.

Keywords

autop

FAQs

Package last updated on 08 May 2018

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