Skip to content

CustomChat warning with minimized attribute being a boolean #227

@isergeevv

Description

@isergeevv

Hi.

Using react@18.2.0 and react-facebook@9.0.12, on initial page render i get this warning in console:

Warning: Received `true` for a non-boolean attribute `minimized`.

If you want to write it to the DOM, pass a string instead: minimized="true" or minimized={value.toString()}.

CustomChatComponent.tsx

'use client';

import { FacebookProvider, CustomChat } from 'react-facebook';

export default () => {
  return (
    <FacebookProvider appId={process.env.NEXT_PUBLIC_FB_CHAT_APP_ID} chatSupport>
      <CustomChat pageId={process.env.NEXT_PUBLIC_FB_CHAT_PAGE_ID} minimized={true} />
    </FacebookProvider>
  );
};

Component works fine it's just the warning.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions