Passing data from server components to client components
Unanswered
American Staffordshire Terrier posted this in #help-forum
American Staffordshire TerrierOP
Hey all. So I’m trying to create a nav component that accepts an array of navlink objects. Each object will contain a label, icon, and onClick properties. This is a client component. Problem is I can’t pass the navlink object in as a prop from a server component (page.tsx) since it contains functions such as the onClick and icon. Can anyone suggest a solution to this that is not “make your page a client component!â€
Ps. Would love to learn how people handle navs in general. Not referring to navbar main but more like icons and tool navs and the like. Subnav maybe?
Ps. Would love to learn how people handle navs in general. Not referring to navbar main but more like icons and tool navs and the like. Subnav maybe?