[{"data":1,"prerenderedAt":427},["ShallowReactive",2],{"blog-why-all-logiclives-in-the-edges":3},{"id":4,"title":5,"body":6,"description":402,"extension":416,"meta":417,"navigation":421,"path":422,"seo":423,"sitemap":424,"stem":425,"__hash__":426},"blog\u002Fblog\u002Fwhy-all-logiclives-in-the-edges.md","Why All Logic Lives in the Edges",{"type":7,"value":8,"toc":401},"minimark",[9,24,27,32,35,62,69,72,81,85,88,102,105,136,143,147,154,157,176,179,193,200,204,209,212,233,236,241,245,248,259,263,266,285,288,302,306,317,324,338,345,352,356,362,365,382,385,394],[10,11,12],"blockquote",{},[13,14,15,16,19,23],"p",{},"If connecting two nodes with an edge already forms a causal relationship -",[17,18],"br",{},[20,21,22],"em",{},"\"If A happens, then B follows\""," -\nthen why should logic be defined anywhere else?",[13,25,26],{},"That question became the foundation of Wanderer's architecture.",[28,29,31],"h2",{"id":30},"the-initial-insight-causality-through-connection","The Initial Insight: Causality Through Connection",[13,33,34],{},"In many visual flow builders, connecting two nodes with an arrow (or \"edge\") implies a relationship:",[36,37,38,46,52,57],"ul",{},[39,40,41,45],"li",{},[42,43,44],"strong",{},"If"," this message was shown,",[39,47,48,51],{},[42,49,50],{},"then"," ask this question.",[39,53,54,56],{},[42,55,44],{}," this API returned true,",[39,58,59,61],{},[42,60,50],{}," continue here.",[13,63,64,65,68],{},"The edge ",[42,66,67],{},"represents logic"," - even if it's just temporal (\"then do this\") or conditional (\"if this, then that\").",[13,70,71],{},"So the next step was obvious:",[10,73,74],{},[13,75,76,77,80],{},"What if ",[20,78,79],{},"all"," logic - even complex logical gates - could live in the edges?",[28,82,84],{"id":83},"the-problem-with-other-builders","The Problem With Other Builders",[13,86,87],{},"Most visual tools mix logic in two places:",[36,89,90,96],{},[39,91,92,95],{},[42,93,94],{},"Edges"," for simple connections.",[39,97,98,101],{},[42,99,100],{},"Nodes"," for conditions, branching, even scripting.",[13,103,104],{},"This causes problems:",[106,107,108,118,124,130],"ol",{},[39,109,110,113,114,117],{},[42,111,112],{},"Hidden logic",": You don’t know ",[20,115,116],{},"where"," a decision is made.",[39,119,120,123],{},[42,121,122],{},"Inconsistent logic",": Sometimes edges decide, sometimes nodes.",[39,125,126,129],{},[42,127,128],{},"Code in nodes",": Flow becomes dependent on internal node behavior or black-box scripts.",[39,131,132,135],{},[42,133,134],{},"Non-visual logic",": The graph stops being the source of truth.",[13,137,138,139,142],{},"In such systems, the graph is no longer a ",[42,140,141],{},"visual representation of program logic"," - it's just a UI for wiring hidden internals.",[28,144,146],{"id":145},"the-wanderer-approach-edges-as-first-class-logic","The Wanderer Approach: Edges as First-Class Logic",[13,148,149,150,153],{},"In Wanderer, edges aren’t just wires - they are ",[42,151,152],{},"logic gates",".",[13,155,156],{},"Each edge defines:",[36,158,159,165,170],{},[39,160,161,164],{},[42,162,163],{},"Whether"," it can be traversed",[39,166,167],{},[42,168,169],{},"Under which condition",[39,171,172,175],{},[42,173,174],{},"What it means"," for the next node to activate",[13,177,178],{},"Node types remain simple:",[36,180,181,184,187,190],{},[39,182,183],{},"Display a message",[39,185,186],{},"Ask a question",[39,188,189],{},"Store a variable",[39,191,192],{},"Call an API",[13,194,195,196,199],{},"But they never decide ",[42,197,198],{},"what comes next",". That’s the edge’s job.",[28,201,203],{"id":202},"why-this-matters","Why This Matters",[205,206,208],"h3",{"id":207},"_1-visual-logic-is-understandable-logic","1. Visual Logic Is Understandable Logic",[13,210,211],{},"When logic lives in the edges:",[36,213,214,221,227],{},[39,215,216,217,220],{},"You can ",[42,218,219],{},"see"," the condition.",[39,222,216,223,226],{},[42,224,225],{},"combine"," multiple edges into AND \u002F OR gates.",[39,228,216,229,232],{},[42,230,231],{},"trace"," decisions without reading code.",[13,234,235],{},"This aligns perfectly with Wanderer’s goal:",[10,237,238],{},[13,239,240],{},"WYSIWYG logic. What you draw is what it does.",[205,242,244],{"id":243},"_2-logic-is-modular-and-testable","2. Logic Is Modular and Testable",[13,246,247],{},"Since conditions are declared on edges:",[36,249,250,253,256],{},[39,251,252],{},"You can test them in isolation.",[39,254,255],{},"You can reuse the same node with different logic pathways.",[39,257,258],{},"You can modify behavior without touching the node.",[205,260,262],{"id":261},"_3-graphs-become-executable","3. Graphs Become Executable",[13,264,265],{},"Because logic is fully embedded in the graph:",[36,267,268,275,278],{},[39,269,270,271,274],{},"The traversal engine can ",[42,272,273],{},"walk the graph"," and make decisions.",[39,276,277],{},"There’s no need to \"evaluate\" node internals.",[39,279,280,281,284],{},"Logic becomes ",[42,282,283],{},"data",", not code.",[13,286,287],{},"This makes flows easier to:",[36,289,290,293,296,299],{},[39,291,292],{},"Version",[39,294,295],{},"Share",[39,297,298],{},"Fork",[39,300,301],{},"Export",[28,303,305],{"id":304},"example-building-a-logical-gate-visually","Example: Building a Logical Gate Visually",[13,307,308,309,312,313,153],{},"Let’s say we have a ",[42,310,311],{},"node"," that sets the state ",[314,315,316],"code",{},"user.stressed = true",[13,318,319,320,323],{},"You can now create two ",[42,321,322],{},"must-edges"," leading to the next question node:",[36,325,326,332],{},[39,327,328,329],{},"One edge checks: ",[314,330,331],{},"user.stressed == true",[39,333,334,335],{},"Another edge checks: ",[314,336,337],{},"user.age > 30",[13,339,340,341,344],{},"Only if ",[20,342,343],{},"both"," edges are traversed successfully will the next question appear.",[13,346,347,348,351],{},"You’ve just built an ",[42,349,350],{},"AND gate",", entirely visually - and entirely through edges.",[28,353,355],{"id":354},"final-thought-logic-belongs-to-the-connections","Final Thought: Logic Belongs to the Connections",[13,357,358,359,361],{},"Nodes are actions.",[17,360],{},"\nEdges are decisions.",[13,363,364],{},"By giving all logic to the edges, we create a system where:",[36,366,367,372,377],{},[39,368,369],{},[42,370,371],{},"Causality is always visible",[39,373,374],{},[42,375,376],{},"The graph is the program",[39,378,379],{},[42,380,381],{},"Every decision is explicit",[13,383,384],{},"This is what makes Wanderer different.",[13,386,387],{},[388,389,393],"a",{"href":390,"rel":391},"https:\u002F\u002Fwanderer-flow.de\u002Fbuilder",[392],"nofollow","Start the Builder",[13,395,396,397],{},"Title image: ",[388,398,399],{"href":399,"rel":400},"https:\u002F\u002Fpixabay.com\u002Fillustrations\u002Fbrain-left-logic-science-5662028\u002F",[392],{"title":402,"searchDepth":403,"depth":403,"links":404},"",2,[405,406,407,408,414,415],{"id":30,"depth":403,"text":31},{"id":83,"depth":403,"text":84},{"id":145,"depth":403,"text":146},{"id":202,"depth":403,"text":203,"children":409},[410,412,413],{"id":207,"depth":411,"text":208},3,{"id":243,"depth":411,"text":244},{"id":261,"depth":411,"text":262},{"id":304,"depth":403,"text":305},{"id":354,"depth":403,"text":355},"md",{"date":418,"author":419,"headerImage":420},"2025-05-12","Chris","\u002Fimages\u002Fblog\u002Fbrain.jpg",true,"\u002Fblog\u002Fwhy-all-logiclives-in-the-edges",{"title":5,"description":402},{"loc":422},"blog\u002Fwhy-all-logiclives-in-the-edges","VShpgEEu4YPyBnEnAr3-CzK0_Bd6Hce2O_PiAKQxkd0",1786889213828]