Skip to content

Question/Feature Request? Using components in the middle of markdown text? #543

@adueck

Description

@adueck

Is it possible to use an imported component in the middle of say, a markdown paragraph?

For example, let's say I wanted to make a component like this

import React from 'react'

const MultiLing = ({word}) => (
    <strong>{word.a} - {word.b}</strong>
)

export default MultiLing

And then I wanted to use it in an .mdx file like this

import MultiLing from "../components/multi-ling.js"

## Heading 

This is a paragraph and I will put my special <MultiLing word={{a: "word", b: "Wort"}} /> here.  

When it's in the middle of markdown text, the component doesn't get rendered. But it would be super awesome if it could. 🤔

Metadata

Metadata

Assignees

No one assigned

    Labels

    👀 no/externalThis makes more sense somewhere else

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions