Skip to content

EdgeRule

Creates a style rule for edges.

Props

edgeAttributes

selector

  • type: (edge: Edge) => Boolean

  • default: () => true

    The selector function to apply to the edges.

Example

vue
<template>
  ...
  <EdgeRule :selector="rule.selector" :attributes="rule.attributes" />
  ...
</template>
<script setup lang="ts">
import { EdgeRule, EdgeRuleProps } from "@linkurious/ogma-vue";
const rule = ref<EdgeRuleProps>({
  attributes: {
    color: "blue",
  },
  selector: () => true,
});
</script>