
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
@uniwebcms/content-reader
Advanced tools
A JavaScript library for converting Markdown content into ProseMirror-compatible document structures. This library is designed to work seamlessly with TipTap v2 and provides enhanced Markdown parsing capabilities with support for extended syntax.
Enhanced Images: Support for image roles (content, background, icon, gallery) using prefix syntax:


Enhanced Links: Button variants with predefined styles:
[Button Text](button:https://example.com)
Tables with Alignment: Full support for aligned columns:
| Left | Center | Right |
| :--- | :----: | ----: |
| Text | Text | Text |
npm install @uniwebcms/content-reader
Basic usage:
const { markdownToProseMirror } = require("@uniwebcms/content-reader");
const markdown = `
# Hello World
This is a **bold** statement with a [link](https://example.com).
- List item 1
- List item 2
- Nested item
`;
const doc = markdownToProseMirror(markdown);
The library is designed to work seamlessly with TipTap editors:
import { Editor } from "@tiptap/core";
import { markdownToProseMirror } from "@uniwebcms/content-reader";
const editor = new Editor({
content: markdownToProseMirror(markdown),
// ... other TipTap configuration
});
The library supports extended image syntax for different display contexts:
const markdown = `



`;
const doc = markdownToProseMirror(markdown);
// Each image will have a 'role' attribute in its output structure
Tables support column alignment and formatted content:
const markdown = `
| Name | Status | Actions |
|:-----|:------:|--------:|
| John | Active | **Edit** |
| Jane | Away | *View* |
`;
const doc = markdownToProseMirror(markdown);
// Table cells will have appropriate alignment attributes
The library is organized into several modules:
We welcome contributions! Please see our contributing guidelines for details.
Clone the repository:
git clone https://github.com/uniwebcms/content-reader.git
Install dependencies:
npm install
Run tests:
npm test
The project uses Jest for testing. Run the test suite:
npm test
Or in watch mode:
npm run test:watch
Apache License 2.0 - See LICENSE for details.
Developed and maintained by UniWeb CMS. Special thanks to all contributors.
FAQs
Markdown to ProseMirror document structure converter
The npm package @uniwebcms/content-reader receives a total of 5 weekly downloads. As such, @uniwebcms/content-reader popularity was classified as not popular.
We found that @uniwebcms/content-reader demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
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.
Research
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.