example-vue
Skill130 starsChanged 38 days agoApache-2.0View on GitHub
Patterns for using Helios with Vue. Use when building compositions in a Vue environment.
In this repository38 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .github/copilot-instructions.mdCopilot instructions
- llms.txtllms.txt
- skill-creatorSkill
- helios-coreSkill
- animated-video-philosophySkill
- cinematic-product-promo-planSkill
- motion-stylesSkill
- example-canvasSkill
- example-chartjsSkill
- example-d3-animationSkill
- example-framer-motionSkill
- example-gsapSkill
- example-lottieSkill
- example-p5-animationSkill
- example-pixiSkill
- example-podcast-visualizerSkill
- example-reactSkill
- example-signals-animationSkill
- example-solidSkill
- example-svelteSkill
- example-tailwind-animationSkill
- example-threejsSkill
- example-vanillaSkill
- helios-getting-startedSkill
- guided-brand-videoSkill
- guided-cartoon-shortSkill
- motion-design-rulesSkill
- guided-music-videoSkill
- guided-video-recipesSkill
- helios-playerSkill
- helios-rendererSkill
- helios-skillsSkill
- helios-studioSkill
- archive-brollSkill
- create-compositionSkill
- render-videoSkill
- workflow-visualize-dataSkill
The file
Files
Vue Composition Patterns
Integrate Helios into Vue components using the Composition API, Refs, and Watchers.
Quick Start
1. Create useVideoFrame Composable
This composable subscribes to Helios and provides a reactive frame reference.
// composables/useVideoFrame.js
import { ref, onUnmounted } from 'vue';
export function useVideoFrame(helios) {
const frame = ref(helios.currentFrame.peek());
const unsubscribe = helios.subscribe((state) => {
frame.value = state.currentFrame;
});
onUnmounted(() => {
unsubscribe();
});
return frame;
}2. Create Composition Component
<script setup>
import { ref, watch, onMounted } from 'vue';
import { Helios } from '@helios-project/core';
import { useVideoFrame } from './composables/useVideoFrame';
// Initialize Singleton
const helios = new Helios({ duration: 10, fps: 30 });
helios.bindToDocumentTimeline();
if (typeof window !== 'undefined') window.helios = helios;
const canvasRef = ref(null);
const frame = useVideoFrame(helios);
// Draw Function
const draw = () => {
const canvas = canvasRef.value;
if (!canvas) return;
const ctx = canvas.getContext('2d');
// Draw logic
const progress = frame.value / (helios.duration * helios.fps);
ctx.clearRect(0, 0, canvas.width, canvas.height);
ctx.fillRect(progress * canvas.width, 100, 50, 50);
};
// React to frame updates
watch(frame, draw);
// Initial Draw
onMounted(() => {
draw();
});
</script>
<template>
<canvas ref="canvasRef" width="1920" height="1080"></canvas>
</template>Audio Visualization Pattern
For audio visualization, use a computed property to analyze audio data based on the reactive frame or currentTime.
1. Create Audio Analysis Composable
// composables/useAudioData.js
import { computed, unref } from 'vue';
export function useAudioData(buffer, currentTime) {
return computed(() => {
const b = unref(buffer);
const t = unref(currentTime);
if (!b) return { rms: 0, waveform: [] };
const data = b.getChannelData(0);
const sampleRate = b.sampleRate;
const center = Math.floor(t * sampleRate);
// Analysis logic...
return { rms: 0.5, waveform: [] };
});
}2. Use in Component
<script setup>
import { computed, watch } from 'vue';
import { useVideoFrame } from './composables/useVideoFrame';
import { useAudioData } from './composables/useAudioData';
const frame = useVideoFrame(helios);
const currentTime = computed(() => frame.value / helios.fps);
const audioData = useAudioData(buffer, currentTime);
watch(audioData, ({ rms, waveform }) => {
// Draw logic
});
</script>Source Files
- Example:
examples/vue-canvas-animation/ - Example:
examples/vue-audio-visualization/
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

