Code Monkey home page Code Monkey logo

plugin-stackedit's Introduction

plugin-stackedit

集成 StackEdit 到 Halo。

需要注意的是,StackEdit 并不支持在项目内直接集成,所以此插件是参考了 stackedit.js 以 iframe 的方式集成。

开发环境

git clone [email protected]:halo-sigs/plugin-stackedit.git

# 或者当你 fork 之后

git clone [email protected]:{your_github_id}/plugin-stackedit.git
cd path/to/plugin-stackedit
# macOS / Linux
./gradlew pnpmInstall

# Windows
./gradlew.bat pnpmInstall
# macOS / Linux
./gradlew build

# Windows
./gradlew.bat build

修改 Halo 配置文件:

halo:
  plugin:
    runtime-mode: development
    classes-directories:
      - "build/classes"
      - "build/resources"
    lib-directories:
      - "libs"
    fixedPluginPath:
      - "/path/to/plugin-stackedit"

使用方式

  1. Releases 下载最新的 JAR 文件。
  2. 在 Halo 后台的插件管理上传 JAR 文件进行安装。
  3. 启动插件之后,即可在新建文章时选择此编辑器。

plugin-stackedit's People

Contributors

lilgg avatar ruibaby avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

plugin-stackedit's Issues

md编辑渲染问题

halo版本:2.4.0
plugin- stackedit版本:1.0.0
问题描述:在使用插件渲染html语法时,导致原生渲染失败

typora 渲染
image

网页正常渲染

image

使用内嵌编辑器(plugin- stackedit)渲染

image

代码如下:

<p><a style="background-color:black;color:white;text-decoration:none;padding:4px 6px;font-size:12px;line-height:1.2;display:inline-block;border-radius:3px" href="https://www.dpm.org.cn/collection/paint/234597.html" target="_blank" rel="noopener noreferrer"><span style="display:inline-block;padding:2px 3px"><svg xmlns="http://www.w3.org/2000/svg" style="height:12px;width:auto;position:relative;vertical-align:middle;top:-1px;fill:white" viewBox="0 0 32 32"><title>unsplash-logo</title><path d="M20.8 18.1c0 2.7-2.2 4.8-4.8 4.8s-4.8-2.1-4.8-4.8c0-2.7 2.2-4.8 4.8-4.8 2.7.1 4.8 2.2 4.8 4.8zm11.2-7.4v14.9c0 2.3-1.9 4.3-4.3 4.3h-23.4c-2.4 0-4.3-1.9-4.3-4.3v-15c0-2.3 1.9-4.3 4.3-4.3h3.7l.8-2.3c.4-1.1 1.7-2 2.9-2h8.6c1.2 0 2.5.9 2.9 2l.8 2.4h3.7c2.4 0 4.3 1.9 4.3 4.3zm-8.6 7.5c0-4.1-3.3-7.5-7.5-7.5-4.1 0-7.5 3.4-7.5 7.5s3.3 7.5 7.5 7.5c4.2-.1 7.5-3.4 7.5-7.5z"></path></svg></span><span style="display:inline-block;padding:2px 3px">顾恺之 洛神赋图卷</span></a></p>

大佬能看看出现了什么问题么?或者说如何使用原生的渲染呢?

无法保存

编辑内容后,点击保存会显示保存成功,
但是再次点击文章进行编辑的时候文章内容是空白的

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.