0.0.1 • Published 7 months ago

@jonny/remotion-tester v0.0.1

Weekly downloads
-
License
-
Repository
-
Last release
7 months ago

Use Second

A react hook for use with Remotion that returns the current second based on current frame and fps.

Part of Remotion Library Starter as an example hook.

Usage

import { useSecond } from "@jonny/remotion-tester";
import { Composition, AbsoluteFill } from "remotion";
import { render} from React;

export const MyVideo: React.FC = () => {
  const second = useSecond();

  return (
    <AbsoluteFill>
      <h1>Second: {second}</h1>
    </AbsoluteFill>
  );
};

render(
  <Composition
    fps={30}
    durationInFrames={30 * 10}
    component={MyVideo}
    width={1080}
    height={1080}
  />,
  document.getElementById("root")
);

License

This project is licensed under the MIT License - see the LICENSE.md file for details

0.0.1

7 months ago