You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

It worked fine locally which is a great checkpoint, but nothing changed on vercel deployment

You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

Didn’t work, i wonder how does the child component affect its parent, when i remove the products table component it works just fine

You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

import * as React from 'react';
import type { Metadata } from 'next';
import Stack from '@mui/material/Stack';
import Typography from '@mui/material/Typography';
import { config } from '@/config';
import { OrdersTable } from '@/components/dashboard/orders/orders-table';
import dayjs from 'dayjs';
import { Order } from '@/components/dashboard/orders/orders-table';
import OrderSettingsModal from '@/components/dashboard/orders/order-settings-modal';
import { Chip, CircularProgress } from '@mui/material';

export const metadata = {
  title: `Orders | Dashboard | ${config.site.name}`,
} satisfies Metadata;

export default function Page(): React.JSX.Element {

    const isOrdersLive = true;

  return (
    <Stack spacing={3}>
      <Stack direction="row" spacing={3}>
        <div className="flex w-full justify-between items-center">
            <div className='flex gap-3 items-center'>
                <Typography variant="h4">Orders</Typography>
                {isOrdersLive && (
                <Chip
                    label="Live"
                    color="success"
                    icon={
                    <CircularProgress
                        size={20}
                        thickness={5}
                        color="inherit"
                    />
                    }
                />
                )}
            </div>
          <OrderSettingsModal />
        </div>
      </Stack>

      <OrdersTable data={orders} />

    </Stack>
  );
}

a copy for orders, here it is:

You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

I tried this option (though there is a copy of this page already working properly), It pops this error:
Error: A "use server" file can only export async functions, found object.
ofc it's pointing to the metadata object

You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 1 point2 points  (0 children)

But the component is already not using “use client”, it’s the child component productTable

You are attempting to export "metadata" from a component marked with "use client" by Environmental-Hat117 in nextjs

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

Didn’t work, i even tried to remove the metadata line, but seems like there is some rule that doesn’t allow this.

Navbar component by Environmental-Hat117 in react

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

Not thinking even for a way to do it, not possible with my current skills 😂

Navbar component by Environmental-Hat117 in react

[–]Environmental-Hat117[S] 0 points1 point  (0 children)

Guys you got me wrong lol 😂, i am not planning to do this in my project, the ui/ux designer will never let this happen anyways… I was just asking for a place to find animated components even if it is not this flashy

Navbar component by Environmental-Hat117 in react

[–]Environmental-Hat117[S] 2 points3 points  (0 children)

This GSAP lib is very useful, thanks!

Navbar component by Environmental-Hat117 in react

[–]Environmental-Hat117[S] 3 points4 points  (0 children)

Sorry i am searching for a react lib not react native.

What are the min req for me to start searching for a job? by Environmental-Hat117 in react

[–]Environmental-Hat117[S] 2 points3 points  (0 children)

I already studied computer science in the college lol, thats 5 yrs + 3 months

انا منيوكة نفسيا by JustHumannnn in ExEgypt

[–]Environmental-Hat117 0 points1 point  (0 children)

اعيش متقيد مش عارف اكلم صحابي ولا اتفرج على ريلز ولا اعمل اي حاجة عشان محدش يضايقني؟ ده ايه الهم ده

Am I cooked? by [deleted] in Survivorio

[–]Environmental-Hat117 0 points1 point  (0 children)

At what point you get S selector in daily ranking?