定制 beromir/neos-markdown 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

beromir/neos-markdown

Composer 安装命令:

composer require beromir/neos-markdown

包简介

Markdown renderer for Neos CMS.

README 文档

README

Features

Installation

Run the following command in your site package:

composer require --no-update beromir/neos-markdown

Then run composer update in your project root.

Configuration

You can enable or disable the following extensions globally:

Beromir:
    Markdown:
        extensions:
            # GitHub-Flavored Markdown
            gfm: true
            externalLinks: true

Usage

Standalone NodeType

You can use the standalone Markdown NodeType on your pages to render Markdown. Per default the NodeType comes with the options to enable or disable the extensions for it. The Fusion component can be overwritten in your site package. For example, you can include some CSS class names in the HTML output.

Add the Markdown editor to custom NodeTypes

The package comes with two Mixins:

  • Editor Mixin
  • Options Mixin

Add the Mixins to your NodeType:

'Vendor.Site:Content.CustomNodeType':
    superTypes:
        'Neos.Neos:Content': true
        'Beromir.Markdown:Mixin.MarkdownEditor': true
        'Beromir.Markdown:Mixin.MarkdownSettings': true

The Settings Mixin is optional. It allows you to enable or disable the CommonMark extensions for the NodeType. If you do not use the Mixin, the global settings are used.

You have two options to render the Markdown in your Fusion component.

Fusion object:

renderer = afx`
<div>
    <Beromir.Markdown:Markdown/>
</div>
`

Eel helper:

html = ${Beromir.Markdown.Markdown.convertMarkdown(props.markdown)}

统计信息

  • 总下载量: 21
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0
  • 更新时间: 2022-06-16

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固