Skip to content

Mix-Anik/yanbe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Yet Another Node-Based Editor

Features

  • Infinite grid with pan/zoom
  • Auto grid-snapping
  • Ultra-smooth feeling UI
  • Type-aware nodes

Examples

You can check out various usage examples located in examples folder

Development

  • Run npm i to install dependencies.

  • Create testing directory in project root and add index.html file with following contents:

    Details

    Show contents
      <!DOCTYPE html>
      <html lang="en">
      <head>
      <meta charset="UTF-8" />
      <title>Testing</title>
      </head>
      <body>
      <div id="editor">
          <div id="viewport">
          <svg id="connections"></svg>
          </div>
      </div>
      <script type="module">
          import { Editor, Node, Connection } from "/src/lib.js";
    
          const editor = new Editor('editor');
          const nodeA = new Node('Node A', 100, 100);
          const nodeB = new Node('Node B', 300, 250);
          editor.addNode(nodeA);
          editor.addNode(nodeB);
          nodeA.connect(nodeB);
      </script>
      </body>
      </html>
  • Now you can run npm run dev and it will open previously added page in browser which will auto-reload on any code changes.

About

Yet Another Node-Based Editor

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published