Giter Site home page Giter Site logo

ymfe / ydoc Goto Github PK

View Code? Open in Web Editor NEW
671.0 33.0 124.0 31.17 MB

🐶YDoc 是一个更懂你的文档站构建工具,基于 markdown 轻松生成完整静态站点

Home Page: https://hellosean1025.github.io/ydoc

License: Apache License 2.0

HTML 48.35% CSS 26.65% JavaScript 19.95% Shell 0.04% SCSS 5.01%
ymfe ydoc jsdoc docs-generator

ydoc's People

Contributors

amnsss avatar ceelog avatar dependabot[bot] avatar doyoe avatar dwb1994 avatar edwonlim avatar hellosean1025 avatar lwg529 avatar malcolmyu avatar wang508x102 avatar xupaopaopaopao avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ydoc's Issues

mermaid支持

Markdown文档中存在mermaid格式的图片,转HTML没有办法正常显示

在示例Demo中执行ydoc serve报错

YDoc 版本号:

~4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

~windows 10, node10.15.0

复现步骤:

~在Excamples/homepage目录下执行ydoc serve报错

events.js:167
throw er; // Unhandled 'error' event
^
11EB0210-440E-4739-A52C-CB72065DE75D

Error: EPERM: operation not permitted, watch
at FSEvent.FSWatcher._handle.onchange (internal/fs/watchers.js:123:28)
Emitted 'error' event at:
at FSEvent.FSWatcher._handle.onchange (internal/fs/watchers.js:129:12)

期望结果:

~

补充说明:

~

安装完后,没有ydoc命令

YDoc 版本号:

[email protected]

环境(操作系统、Node 版本、浏览器版本等信息):

~centos7, Node 版本 v10.16.0

复现步骤:

~ 安装完后,没有ydoc命令

期望结果:

~ 能正常执行ydoc init

补充说明:

~

windows 下 ydoc serve 报错

YDoc 版本号:

4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

win10专业版
node:v10.6.0

复现步骤:

yarn init 成功
yarn build 成功
yarn serve 报错

\ events.js:167
      throw er; // Unhandled 'error' event
      ^
Error: EPERM: operation not permitted, watch
    at FSEvent.FSWatcher._handle.onchange (internal/fs/watchers.js:120:28)
Emitted 'error' event at:
    at FSEvent.FSWatcher._handle.onchange (internal/fs/watchers.js:126:12)

期望结果:

yarn serve 成功

补充说明:

ydoc.js

module.exports = {
    title: "ydoc-plugin-jsdoc",
    description: "ydoc-plugin-jsdoc description demo",
    author: "ymfe",
    plugins: ['jsdoc'],
    pluginsConfig: {
      jsdoc: {
        files: 'src/**/*.js', // 生成文档源目录
      }
    }
}

侧边导航栏支持折叠

根据 SUMMARY.md 生成的侧边栏,默认都是展开的,如果有大量文档索引的话,不方便定位锚点,希望可以支持折叠。

是否支持像写React一样写jsx

我用ydoc init生成了一个demo,修改jsx之后保存,就被我的vscode格式化乱了,貌似定义内容的语法不是jsx语法,是否可以将这块抽离?

页面跳转后再点击浏览器左上角回退页面,未停留在锚点位置

YDoc 版本号:

~4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

~

复现步骤:

打开 [https://react-hobby.github.io/redux-sam/api/index.html#%e7%bb%84%e4%bb%b6%e7%bb%91%e5%ae%9a%e7%9a%84%e8%be%85%e5%8a%a9%e5%87%bd%e6%95%b0-mapactions),先点击详细介绍,在点击浏览器左上角返回,此时页面停留的位置不是锚点位置

期望结果:

页面回退后停留在跳转前的位置

补充说明:

~

开发建议:是否考虑出一个纯文本站点模式,类似于gitbook

像是gitbook一样,没有首页,仅仅有一个页面。用来浏览书本。

我感觉ydoc在纯文本建站上的体验,已经碾压了gitbook,我个人也用ydoc建过一些说明性质网站了。很期待ydoc的发展。

但是目前虽然有首页,但首页的图标不能很方便设置与替换。而且很多用户可能和我一样,大多数时候需要得可能是一个最简单的单页面。

希望未来能予以考虑!

css 怎么应用上去

YDoc 版本号:

比如,我要给图片添加 width,height 样式 内部设计

添加了custom.css 文件 写入相关样式,ydoc.json 引入 custom.css ,样式怎么去引用到图片上
~

环境(操作系统、Node 版本、浏览器版本等信息):

~

复现步骤:

~

期望结果:

~

补充说明:

~

https://ydoc.ymfe.org/进不去

YDoc 版本号:

~

环境(操作系统、Node 版本、浏览器版本等信息):

~

复现步骤:

~

期望结果:

~

补充说明:

~

ydoc serve 命令只能执行一次,后面必挂

YDoc 版本号:

~
v4.0.3

环境(操作系统、Node 版本、浏览器版本等信息):

~
windows 10 家庭版 x64
npm : 5.3.0
node: 8.3.0
chrome 版本 70.0.3538.77(正式版本) (64 位)

复现步骤:

~
ydoc init 创建项目

ydoc serve 启动
访问正常

然后 ctrl +c 停止

然后
ydoc serve
再也没有成功过

期望结果:

~
每次都能正常执行

补充说明:

~
没有ydoc serve 的话,我不可能考虑用这个,

搜索显示对应不上

image
您好,我比较关注搜索功能,这个您看看可能是什么原因导致的呢,非常感谢

method 的 @skip 参数无效

/**
 * 日历选择组件
 * 
 * @component Calendar
 * @version 1.0.0
 */

/**
 * @method _initEvent
 * @description 初始化
 * @skip
 */   

上面的代码,依旧会将 _initEvent 生成文档。

无法更换logo

YDoc 版本号:

~

环境(操作系统、Node 版本、浏览器版本等信息):

~

复现步骤:

~

期望结果:

~

补充说明:

~

不支持中文等特殊符号的路径

【问题截图】
包含有特殊符号的中文路径不能正确的编译
build后的截图
image

发布后访问截图
image

【期望】GitBook效果
在GitBook中是可以正常访问的
image

侧边栏分级功能

需要在多页配置的情况下,能够支持侧边栏分级。比如:侧边栏有A和B两个大的分类,A下面还有a1,a2,a3等细分类,每个对应单独的页面。

表格生成有问题

当用 markdown 生成文档的时候,如果使用表格,表格最后一行的最后一项如果为空,则显示不正确
image

Template Error

我用在js文件里加了ydoc注释 ydoc build之后就出现了这个问题 还是好多个文件都出现这个问题 希望大神们可以帮我看一下是什么问题

 生成文件: /Users/Documents/word/rnx-ui/doc/component-ImgHolder.html
Template Error

<filename>
undefined

<name>
Render Error

<message>
Cannot read property 'replace' of undefined
Please report this to https://github.com/chjj/marked.

<line>
7

<source>
<div class="api-content">{{description | markdown}}</div>

ydoc serve报错

YDoc 版本号:

~4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

~win7 64位 ,node(8.16.0), npm(6.4.1)

复现步骤:

~ydoc init(成功)
~ydoc build(成功)
~ydoc serve(失败),报错
`\ events.js:183
throw er; // Unhandled 'error' event
^

Error: Error watching file for changes: EPERM
at FSEvent.FSWatcher._handle.onchange (fs.js:1359:9)
`

期望结果:

~成功,提示可以在浏览器地址127.0.0.1:9999访问

补充说明:

~

xss 漏洞

YDoc 版本号:

~ *

环境(操作系统、Node 版本、浏览器版本等信息):

~ 有使用搜索插件

复现步骤:

~ 搜索框输入 ><img src="1" onerror="alert('渗透 XSS')">

期望结果:

~ 出现弹框

补充说明:

~结合不安全jquery版本可能会导致安全问题

ydoc serve 报错

YDoc 版本号:

~ v4.1.1

环境(操作系统、Node 版本、浏览器版本等信息):

~ win7

复现步骤:

image

期望结果:

~不报错

补充说明:

~

编译index.jsx报错

YDoc 版本号:

4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

MacOS Mojave 10.14.5

复现步骤:

修改index.jsx,在desc里面写入转义符和单引号\', 然后build的时候就报错

期望结果:

正常编译成html,建议直接支持json格式,或者支持pug模版。另外上次你回复的那种方法不能修改搜索框里面的中文占位符。

补充说明:

error: { YAMLException: missed comma between flow collection entries at line 10, column 38:
     ...  name: 'Modular', desc: 'celia\'s modular methods are great for  ... 
                                         ^
    at generateError (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:167:10)
    at throwError (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:173:9)
    at readFlowCollection (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:718:7)
    at composeNode (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1360:11)
    at readBlockMapping (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1036:16)
    at composeNode (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1359:12)
    at readBlockSequence (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:955:5)
    at composeNode (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1358:12)
    at readBlockMapping (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1089:11)
    at composeNode (/Users/jesse/.nvm/versions/node/v8.16.0/lib/node_modules/ydoc/node_modules/[email protected]@js-yaml/lib/js-yaml/loader.js:1359:12)
  name: 'YAMLException',
  reason: 'missed comma between flow collection entries',

ydoc每天自动挂掉

YDoc 版本号:

4.1.0

环境(操作系统、Node 版本、浏览器版本等信息):

操作系统:centos
Node版本:10.15.3

复现步骤:

使用nohup ydoc serve > nohup.out 2>&1 &在服务器上后台运行ydoc服务
每天晚上9点之后--早上9点之前,服务自动挂掉

报错信息如下:

 Error: write ECONNRESET
      at WriteWrap.afterWrite [as oncomplete] (net.js:779:14) 

补充:

之前部署的ydoc服务已经良好运行了半年,12月5日早上服务挂掉后,我误使用了ydoc init命令,对之前的ydoc目录做了重置,再次运行ydoc serve之后,出现了上述情况;

目录折叠

目录能否支持折叠?现在都是直接平铺的,当目录较多的时候,不好快速根据一级目录查找

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.