mdx-editor / mdx-editor/editor
[BUG] The maxLength and diffSource plugins don’t work well together.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 3.7k
- Forks
- 307
- Avg merge
- 14h 22m
- Merged PRs (30d)
- 5
Description
- I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
- I have read the documentation and cannot find an answer.
Describe the bug
You can bypass the maxLength character limit when you're in source mode.
To Reproduce
Steps to reproduce the behavior:
- Create the Editor with those plugins.
- Click on Source-mode button
- Type until you exceed the limit defined in the plugin.
- See error
Expected behavior
I expected the limit is consistent across all modes.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: [e.g. MacOS, Windows] - Windows can act funny sometimes.
- Browser [e.g. Chrome, Safari]
Additional context
Add any other context about the problem here.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the maxLength and diffSource plugin implementations and reproduce the issue by switching to source mode and exceeding the configured limit. Done means the character limit is enforced consistently in both modes, with coverage for their combined use.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100