关于 文本比较
按字符、单词或行查看差异
The comparison mode should match the change you are reviewing. Line mode is easier for configuration and source files, while word or character mode can reveal a small edit inside a line; whitespace and line-ending settings can change the result substantially.
如何使用这个开发者工具
- Paste the original and revised text into the two panes.
- Choose character, word, or line comparison and set whitespace options deliberately.
- Review additions, removals, and unchanged context, then copy the relevant result or return to the source file for the final edit.
隐私与数据处理
The diff is calculated locally in the browser. Use shortened or redacted samples for logs, documents, and source code that should not be shared with a public service.
相关开发者工具
常见问题
Why does the whole file look changed?
Different line endings, indentation, encoding, or whitespace can make every line appear different. Check the comparison options before judging the content change.
Which comparison mode should I use?
Use line mode for files and configuration, word mode for prose or structured text, and character mode for small values where the exact position matters.
Does a diff prove which version is correct?
No. It shows differences only. Use tests, review, and the source system to decide which version should be kept.