Skip to content

Documentation for custom components #362

@haydenbleasel

Description

@haydenbleasel

i have this bug where rehype-raw doesn't seem to work for custom components unless i explicitly declare it else it will ignore it and wont show it. can you please check this as well, thanks.

 components={
              {
                chunkref: ({
                  id,
                  index,
                  node,
                  ...rest
                }: {node?: unknown} & ChunkRefProps) => (
                  <ChunkRef
                    id={id}
                    index={index}
                    messageId={messageId}
                    onOpenSource={onOpenSource}
                    {...rest}
                  />
                ),
              } as React.ComponentProps<typeof Response>['components']
            }
            
            
 rehypePlugins={[
              {
                plugins: [rehypeRaw, rehypeKatex, harden],
              },
            ]}

Originally posted by @corolair-hazem in #331 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions