From 5538a6ae0be875fa1c53f8e3959875cecba3c1e8 Mon Sep 17 00:00:00 2001 From: sthag Date: Mon, 20 Apr 2026 22:58:40 +0200 Subject: [PATCH] feat: Add sample function to app --- source/code/hippie/app.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/code/hippie/app.js b/source/code/hippie/app.js index 60eeeef..89af792 100644 --- a/source/code/hippie/app.js +++ b/source/code/hippie/app.js @@ -657,6 +657,10 @@ class RandomPixelPlaceholder { } } +function sample(array) { + return array[Math.floor(Math.random() * array.length)]; +} + // CONCEPTS // NOTE: Benutzt private Zuweisungen