yuml-diagram

UML diagramming package based on the yUML syntax
授权协议 MIT License
开发语言 JavaScript
所属分类 Web应用开发、 常用JavaScript包
软件类型 开源软件
地区 不详
投 递 者 查淮晨
操作系统 跨平台
开源组织
适用人群 未知
 软件概览

yUML diagrammer

Allows the creation of offline UML diagrams based on the yUML Syntax.

Features

  • Currently, the following diagram types are supported:
    • Class
    • Activity
    • Use-case
    • State
    • Deployment
    • Package
    • Sequence
  • Additional directives for altering diagram type and orientation
  • Embedded rendering engine: No need to call an external web service

yUML syntax

Please refer to the wiki page

Installation

This library is published as a npm package here. For installing use:

npm install yuml-diagram

Usage example

const yuml_diagram = require('yuml-diagram');

var yuml = new yuml_diagram();
var svgLightBg = yuml.processYumlDocument(yumlText, false);
var svgDarkBg = yuml.processYumlDocument(yumlText, true);

Try a live example with RunKit: https://runkit.com/embed/r21r931hzoqm

Browserified distribution

For using this library in a browser application, include the script at /dist/yuml-diagram.min.js in your project.

The following example shows how to use it:

<html>
    <head>
        <script src="yuml-diagram.min.js"></script>
        <script>
            function loadSvg()
            {
                var yumlText = 
                    `// {type:class}
                    [A]->[B]`;

                // Generate the diagram
                var yuml  = new yuml_diagram();
                var svg = yuml.processYumlDocument(yumlText, false);

                document.body.innerHTML = svg;
            }
        </script>
    </head>
    <body onload="loadSvg();">        
    </body>
</html>

Contributing

For pull requests, please read CONTRIBUTING.md

Have a nice diagram to show? Please send it for publishing here!

Credits

  • Syntax and some examples taken from yuml.me
  • This package embeds a Javascript port of Dot/Graphviz called viz.js
  • The yuml-to-dot translator is loosely based on a Python project called scruffy
  • The new sequence diagram is based on this github fork
  • The yUML syntax is based on the samples provided in yuml.me. There is not a formal documentation, so this page pretends to centralize the information gathered, plus some proposed extensions for new di

  • 一、yum配置文件的简单介绍   在resources目录下,可以放入spring boot的全局配置文件。spring boot全局配置文件的命名默认如下: application.properties application.yml 配置文件的作用:修改SpringBoot自动配置的默认值。 什么是yum文件? YAML(YAML Ain’t Markup Language) YAML A M

  • 绪论   在UML中,使用组件图来可视化物理组件以及它们间的关系,并描述其构造细节。组件图描述软件组件以及组件之间的关系,组件本身是代码的物理模块,组件图则显示了代码的结构。在UML中,任何一个组件图都不能描述系统实现视图的所有方面,当系统中的组件组合起来才能表示系统完整的实现视图,而其中的一个组件图只是实现视图的一部分。 芝士 组件图包含的元素 组件 系统中可替换的物理部件 类型 配置组件(De

相关阅读

相关文章

相关问答

相关文档