• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

source-academy / js-slang / 23995741899

05 Apr 2026 06:14AM UTC coverage: 77.093% (+0.002%) from 77.091%
23995741899

push

github

web-flow
Upgrade to TypeScript 6 and Prettier improvements (#1936)

* Upgrade TypeScript to v6

* Fix import source

* Fix tsconfig

* Fix preexisting type errors

* Remove scm-slang

* Bump node types

* Fix tsconfig

* Fix node types specifier

* Enable trailing commas

* Enable semicolons

* Check and commit files with changed line numbers

* Update Yarn to 4.13.0

* Remove unneeded sicp package deps

3112 of 4282 branches covered (72.68%)

Branch coverage included in aggregate %.

3761 of 5218 new or added lines in 152 files covered. (72.08%)

26 existing lines in 9 files now uncovered.

7136 of 9011 relevant lines covered (79.19%)

175254.05 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.71
/src/parser/source/rules/noExportNamedDeclarationWithDefault.ts
1
import type { ExportNamedDeclaration } from 'estree';
2
import { defaultExportLookupName } from '../../../stdlib/localImport.prelude';
3
import { mapAndFilter } from '../../../utils/misc';
4
import { RuleError } from '../../errors';
5
import type { Rule } from '../../types';
6
import syntaxBlacklist from '../syntax';
7

8
export class NoExportNamedDeclarationWithDefaultError extends RuleError<ExportNamedDeclaration> {
9
  public explain() {
10
    return 'Export default declarations are not allowed.';
2✔
11
  }
12

13
  public elaborate() {
NEW
14
    return 'You are trying to use an export default declaration, which is not allowed (yet).';
×
15
  }
16
}
17

18
const noExportNamedDeclarationWithDefault: Rule<ExportNamedDeclaration> = {
65✔
19
  name: 'no-declare-mutable',
20
  disableFromChapter: syntaxBlacklist['ExportDefaultDeclaration'],
21

22
  checkers: {
23
    ExportNamedDeclaration(node) {
24
      return mapAndFilter(node.specifiers, specifier =>
30✔
25
        specifier.exported.name === defaultExportLookupName
10✔
26
          ? new NoExportNamedDeclarationWithDefaultError(node)
27
          : undefined,
28
      );
29
    },
30
  },
31
};
32

33
export default noExportNamedDeclarationWithDefault;
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc