docs: update examples

This commit is contained in:
braks
2022-11-13 19:13:43 +01:00
committed by Braks
parent f6a97c504b
commit cd03034bdb
35 changed files with 222 additions and 161 deletions
+3 -2
View File
@@ -1,11 +1,10 @@
<script setup>
import { Background, Controls, MiniMap } from '@vue-flow/additional-components'
import { ConnectionMode, VueFlow, useVueFlow } from '@vue-flow/core'
import { VueFlow, useVueFlow } from '@vue-flow/core'
import { onMounted } from 'vue'
const { onConnect, nodes, edges, addEdges, addNodes } = useVueFlow({
fitViewOnInit: true,
connectionMode: ConnectionMode.Loose,
// set this to true so edges get elevated when selected, defaults to false
elevateEdgesOnSelect: true,
nodes: [
@@ -88,7 +87,9 @@ onMounted(() => {
<template>
<VueFlow>
<MiniMap />
<Controls />
<Background />
</VueFlow>
</template>