In-browser code editor (version 5, legacy)
This report summarizes scanner evidence for codemirror/codemirror5, a JavaScript project with 27,196 GitHub stars. SynthScan examined 98,820 lines of code across 567 source files, recording 76 pattern matches distributed across 9 syntactic categories. The legacy adjusted pattern signal is 1.2 (Low pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.
Can maintainers explain intent, assumptions, and trade-offs? 51 finding(s).
Are imports declared and package/API names verified? 18 finding(s).
Are wrappers, guards, and repeated structures necessary? 32 finding(s).
Which changes need focused human review? 76 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 76 distinct pattern matches across 9 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/mode_test.js | 161 | function highlightOutputsDifferent(o1, o2) { | CODE |
| LOW | mode/clojure/test.js | 363 | function testFormsThatHaveBodyParameter(forms) { | CODE |
| LOW | mode/dart/dart.js | 135 | function tokenInterpolationIdentifier(stream, state) { | CODE |
| LOW | mode/markdown/test.js | 47 | function FormatTokenTypeOverrideTest(name) { test.mode(name, modeFormattingOverride, Array.prototype.slice.call(argume | CODE |
| LOW | mode/powershell/powershell.js | 284 | function tokenHereStringInterpolation(stream, state) { | CODE |
| LOW | mode/slim/slim.js | 265 | function startAttributeWrapperMode(state, endQuote, tokenize) { | CODE |
| LOW | mode/sass/sass.js | 108 | function buildInterpolationTokenizer(currentTokenizer) { | CODE |
| LOW | mode/sql/sql.js | 226 | function hookIdentifierDoublequote(stream) { | CODE |
| LOW | addon/merge/merge.js | 789 | function collapseIdenticalStretches(mv, margin) { | CODE |
| LOW | addon/comment/continuecomment.js | 93 | function continueLineCommentEnabled(cm) { | CODE |
| LOW | addon/search/searchcursor.js | 45 | function searchRegexpForwardMultiline(doc, regexp, start) { | CODE |
| LOW | addon/search/searchcursor.js | 102 | function searchRegexpBackwardMultiline(doc, regexp, start) { | CODE |
| LOW | addon/search/search.js | 220 | function getReplacementQueryDialog(cm) { | CODE |
| LOW | addon/edit/continuelist.js | 67 | function incrementRemainingMarkdownListNumbers(cm, pos) { | CODE |
| LOW | src/measurement/position_measurement.js | 76 | function updateExternalMeasurement(cm, line) { | CODE |
| LOW⚡ | src/measurement/position_measurement.js | 252 | function maybeUpdateRectForZooming(measure, rect) { | CODE |
| LOW⚡ | src/measurement/position_measurement.js | 262 | export function clearLineMeasurementCacheFor(lineView) { | CODE |
| LOW⚡ | src/measurement/position_measurement.js | 271 | export function clearLineMeasurementCache(cm) { | CODE |
| LOW | src/line/spans.js | 242 | export function conflictingCollapsedRange(doc, lineNo, from, to, marker) { | CODE |
| LOW | src/line/line_data.js | 121 | export function defaultSpecialCharPlaceholder(ch) { | CODE |
| LOW | src/model/changes.js | 212 | function makeChangeSingleDocInEditor(cm, change, spans) { | CODE |
| LOW | src/model/line_widget.js | 54 | function adjustScrollWhenAboveVisible(cm, line, diff) { | CODE |
| LOW | src/model/history.js | 105 | function selectionEventCanBeMerged(doc, origin, prev, sel) { | CODE |
| LOW | src/model/selection_updates.js | 85 | export function setSelectionReplaceHistory(doc, sel, options) { | CODE |
| LOW | src/display/line_numbers.js | 32 | export function maybeUpdateLineNumberWidth(cm) { | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | mode/coffeescript/index.html | 54 | # -------------- | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 123 | # -------------------- | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 296 | # --------------- | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 405 | # ------------------ | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 464 | # ---------------- | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 597 | # ----------------- | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 681 | # --------------------- | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | demo/matchhighlighter.html | 43 | Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut pharetra | CODE |
| LOW⚡ | demo/matchhighlighter.html | 43 | Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut pharetra | CODE |
| LOW⚡ | demo/matchhighlighter.html | 49 | sagittis felis a, pellentesque mauris. Lorem ipsum dolor sit amet, | CODE |
| LOW⚡ | demo/matchhighlighter.html | 49 | sagittis felis a, pellentesque mauris. Lorem ipsum dolor sit amet, | CODE |
| LOW | demo/matchhighlighter.html | 75 | Nam rhoncus, est blandit auctor auctor, lorem ipsum laoreet ipsum, | CODE |
| LOW | demo/hardwrap.html | 29 | <form><textarea id="code" name="code">Lorem ipsum dolor sit amet, vim augue dictas constituto ex, | CODE |
| LOW | demo/hardwrap.html | 29 | <form><textarea id="code" name="code">Lorem ipsum dolor sit amet, vim augue dictas constituto ex, | CODE |
| LOW | demo/simplescrollbars.html | 33 | Lorem ipsum dolor sit amet, turpis nec facilisis neque vestibulum adipiscing, magna nunc est luctus orci a, | CODE |
| LOW | demo/simplescrollbars.html | 33 | Lorem ipsum dolor sit amet, turpis nec facilisis neque vestibulum adipiscing, magna nunc est luctus orci a, | CODE |
| LOW | mode/textile/test.js | 80 | 'user@example.com'); | CODE |
| LOW | mode/rst/index.html | 419 | Lorem ipsum [#f1]_ dolor sit amet ... [#f2]_ | CODE |
| LOW | mode/rst/index.html | 419 | Lorem ipsum [#f1]_ dolor sit amet ... [#f2]_ | CODE |
| LOW | mode/rst/index.html | 437 | Lorem ipsum [Ref]_ dolor sit amet. | CODE |
| LOW | mode/rst/index.html | 437 | Lorem ipsum [Ref]_ dolor sit amet. | CODE |
| LOW | addon/hint/css-hint.js | 20 | "placeholder":1, "read-only":1, "read-write":1, "required":1, "root":1, | CODE |
| LOW | addon/display/placeholder.js | 12 | CodeMirror.defineOption("placeholder", "", function(cm, val, old) { | CODE |
| LOW | addon/display/placeholder.js | 45 | var placeHolder = cm.getOption("placeholder") | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | mode/coffeescript/index.html | 106 | # Create a safe reference to the Underscore object for use below. | COMMENT |
| MEDIUM | mode/coffeescript/index.html | 407 | # Create a function bound to a given object (assigning `this`, and arguments, | COMMENT |
| MEDIUM | mode/puppet/index.html | 55 | # Create a subdirectory in /etc for config files | COMMENT |
| MEDIUM | mode/puppet/index.html | 63 | # Create an example backup file, useful for reference | COMMENT |
| MEDIUM | mode/puppet/index.html | 91 | # Create the base backup directory | COMMENT |
| MEDIUM | mode/ruby/index.html | 97 | # Create a string of the polynomial in sort-of-readable form. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/test.js | 1621 | // Good: | COMMENT |
| LOW | mode/markdown/test.js | 181 | // Unclosed backticks | COMMENT |
| LOW | mode/erlang/erlang.js | 461 | } | COMMENT |
| LOW | mode/tcl/index.html | 21 | <li><a href="../index.html">Language modes</a> | COMMENT |
| LOW | mode/tcl/index.html | 41 | ## ## Start Setup. ## ## | COMMENT |
| LOW | mode/sas/sas.js | 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others | COMMENT |
| LOW | mode/coffeescript/index.html | 21 | <li><a class=active href="#">CoffeeScript</a> | COMMENT |
| LOW | mode/coffeescript/index.html | 41 | # **Underscore.coffee | COMMENT |
| LOW | mode/rpm/index.html | 61 | indentUnit: 4 | COMMENT |
| LOW | addon/search/match-highlighter.js | 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others | COMMENT |
| LOW | addon/tern/tern.js | 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others | COMMENT |
| LOW | addon/tern/tern.js | 21 | // multi-file view, switch the view or focus to the named file. | COMMENT |
| LOW | src/util/bidi.js | 41 | // One-char codes used for character types: | COMMENT |
| LOW | src/model/chunk.js | 1 | import { cleanUpLine } from "../line/line_data.js" | COMMENT |
| LOW | src/model/mark_text.js | 21 | // handle that can be used to clear or find a marked position in the | COMMENT |
| LOW | src/display/scroll_events.js | 1 | import { chrome, chrome_version, gecko, ie, mac, presto, safari, webkit } from "../util/browser.js" | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | src/input/ContentEditableInput.js | 134 | return this.cm.display.wrapper.ownerDocument.getSelection() | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | doc/releases.html | 871 | <li><a href="https://codemirror.net/5/doc/manual.html#addon_merge">merge addon</a>: Make aligning of unchanged chunk | CODE |
| MEDIUM | doc/releases.html | 871 | <li><a href="https://codemirror.net/5/doc/manual.html#addon_merge">merge addon</a>: Make aligning of unchanged chunk | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | doc/manual.html | 172 | <p>Here's a simple example of using RequireJS to load CodeMirror:</p> | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | mode/ruby/index.html | 102 | # Assign exponents to each term, making pairs of coeff and exponent, | COMMENT |