Closed diptasahacse closed 1 year ago
Add 'use client';
to the top of your file.
"use client"
on top of file work well in my case. Thank you @Al-Ghoul
"use client"
isn't working for me. I tried add it in page.js but didn't work. I also created a new file used "use client"
and exported in page.js but it also didn't work.
I am getting issues while using in Next JS,
Type.tsx import React from "react"; import Typewriter from "typewriter-effect"; const Type = () => { return ( <Typewriter options={{ strings: ["JavaScript", "TypeScript", "React", "NextJS", "NodeJS"], autoStart: true, loop: true, deleteSpeed: 50, }} /> ); };
export default Type;
I used that components in another component like,
Hero.tsx
import React from "react"; import Type from "../Shared/Type"; const Hero = () => { return (
); };
export default Hero;