This project is based on LingDong's Handpose Demos using mediapipe handpose with tensorflow.js.
From the tracking points mediapipe delivered, I calculated two additional points that gave me a line at a right angle to the edge of the hand, which gave me the vector for the saber beam, and from there on it was only a matter of finetunig the positioning. UnrealBloomPass doesn't work on a transparent background, so I replaced it with PMNDRS Three Post Processing. It looks awkward without a prop in your hand though, so grab a pen or something!
A lightsaber is nothing without sound, so I added tone.js to create the hum. I know nothing whatsoever about synthesizers, so I had to fumble my way through with the thankfully extensive documentation.