Skip to content

Instantly share code, notes, and snippets.

@kiritocode1
Last active September 22, 2024 07:21
Show Gist options
  • Select an option

  • Save kiritocode1/3ccfff19360215873f71fc3c91559ae9 to your computer and use it in GitHub Desktop.

Select an option

Save kiritocode1/3ccfff19360215873f71fc3c91559ae9 to your computer and use it in GitHub Desktop.
replicating youtube effect in a speedrun : 2 hrs
"use client";
import { FC, useEffect, useRef } from "react";
interface pageProps {}
const Page: FC<pageProps> = ({}) => {
return (
<div className="flex min-h-screen bg-black relative items-center justify-center min-w-full">
<video
className="w-[600px] max-w-full h-auto absolute z-20 translate-x-1/2 translate-y-[60%] scale-[1.5_1.3] rounded-[30%] blur-[100px] saturate-200 opacity-50"
autoPlay
loop
muted
playsInline
id="videoGojo"
>
<source src="/videos/gojo.mp4" type="video/mp4" />
</video>
<video
className="w-[600px] max-w-full h-auto absolute z-30 "
autoPlay
loop
muted
playsInline
id="videoGojo"
>
<source src="/videos/gojo.mp4" type="video/mp4" />
</video>
</div>
);
};
export default Page;
@kiritocode1

Copy link
Copy Markdown
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment