@mui/internal-code-infra 0.0.4-canary.3 → 0.0.4-canary.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -8
- package/build/babel-config.d.mts +11 -3
- package/build/brokenLinksChecker/crawlWorker.d.mts +1 -0
- package/build/brokenLinksChecker/index.d.mts +35 -2
- package/build/changelog/types.d.ts +1 -1
- package/build/cli/cmdArgosPush.d.mts +2 -2
- package/build/cli/cmdBuild.d.mts +2 -2
- package/build/cli/cmdCopyFiles.d.mts +2 -2
- package/build/cli/cmdExtractErrorCodes.d.mts +2 -2
- package/build/cli/cmdGenerateChangelog.d.mts +2 -2
- package/build/cli/cmdGithubAuth.d.mts +2 -2
- package/build/cli/cmdListWorkspaces.d.mts +4 -2
- package/build/cli/cmdNetlifyIgnore.d.mts +2 -2
- package/build/cli/cmdPublish.d.mts +4 -2
- package/build/cli/cmdPublishCanary.d.mts +3 -2
- package/build/cli/cmdPublishNewPackage.d.mts +4 -2
- package/build/cli/cmdSetVersionOverrides.d.mts +2 -2
- package/build/cli/cmdVale.d.mts +46 -0
- package/build/cli/cmdValidateBuiltTypes.d.mts +2 -2
- package/build/eslint/mui/rules/disallow-react-api-in-server-components.d.mts +2 -2
- package/build/eslint/mui/rules/docgen-ignore-before-comment.d.mts +2 -2
- package/build/eslint/mui/rules/no-restricted-resolved-imports.d.mts +2 -2
- package/build/markdownlint/duplicate-h1.d.mts +1 -1
- package/build/markdownlint/git-diff.d.mts +1 -1
- package/build/markdownlint/index.d.mts +1 -1
- package/build/markdownlint/straight-quotes.d.mts +1 -1
- package/build/markdownlint/table-alignment.d.mts +1 -1
- package/build/markdownlint/terminal-language.d.mts +1 -1
- package/build/utils/build.d.mts +3 -3
- package/build/utils/github.d.mts +1 -1
- package/build/utils/pnpm.d.mts +68 -2
- package/build/utils/testUtils.d.mts +7 -0
- package/package.json +38 -31
- package/src/babel-config.mjs +9 -3
- package/src/brokenLinksChecker/__fixtures__/static-site/index.html +1 -0
- package/src/brokenLinksChecker/__fixtures__/static-site/invalid-html.html +15 -0
- package/src/brokenLinksChecker/crawlWorker.mjs +173 -0
- package/src/brokenLinksChecker/index.mjs +177 -164
- package/src/brokenLinksChecker/index.test.ts +55 -13
- package/src/build-env.d.ts +13 -0
- package/src/changelog/fetchChangelogs.mjs +6 -2
- package/src/changelog/types.ts +1 -1
- package/src/cli/cmdListWorkspaces.mjs +9 -2
- package/src/cli/cmdNetlifyIgnore.mjs +4 -88
- package/src/cli/cmdPublish.mjs +51 -14
- package/src/cli/cmdPublishCanary.mjs +139 -107
- package/src/cli/cmdPublishNewPackage.mjs +27 -6
- package/src/cli/cmdVale.mjs +513 -0
- package/src/cli/cmdVale.test.mjs +644 -0
- package/src/cli/index.mjs +2 -0
- package/src/eslint/baseConfig.mjs +2 -1
- package/src/eslint/docsConfig.mjs +2 -1
- package/src/eslint/jsonConfig.mjs +2 -1
- package/src/eslint/mui/config.mjs +11 -1
- package/src/eslint/testConfig.mjs +2 -1
- package/src/estree-typescript.d.ts +1 -1
- package/src/untyped-plugins.d.ts +11 -11
- package/src/utils/build.test.mjs +546 -575
- package/src/utils/pnpm.mjs +192 -3
- package/src/utils/pnpm.test.mjs +580 -0
- package/src/utils/testUtils.mjs +18 -0
- package/src/utils/typescript.test.mjs +249 -272
- package/vale/.vale.ini +1 -0
- package/vale/styles/MUI/CorrectReferenceAllCases.yml +43 -0
- package/vale/styles/MUI/CorrectRererenceCased.yml +14 -0
- package/vale/styles/MUI/GoogleLatin.yml +11 -0
- package/vale/styles/MUI/MuiBrandName.yml +22 -0
- package/vale/styles/MUI/NoBritish.yml +112 -0
- package/vale/styles/MUI/NoCompanyName.yml +17 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
// TODO: change back to 'eslint/config' once https://github.com/eslint/rewrite/issues/425 is fixed
|
|
2
|
+
import { defineConfig } from '@eslint/config-helpers';
|
|
2
3
|
|
|
3
4
|
const restrictedMethods = ['setTimeout', 'setInterval', 'clearTimeout', 'clearInterval'];
|
|
4
5
|
|
|
@@ -499,6 +500,15 @@ export function createCoreConfig(options = {}) {
|
|
|
499
500
|
message: 'Do not call `Error(...)` without `new`. Use `new Error(...)` instead.',
|
|
500
501
|
selector: "CallExpression[callee.name='Error']",
|
|
501
502
|
},
|
|
503
|
+
{
|
|
504
|
+
// xmlns="http://www.w3.org/2000/svg" is only needed on standalone .svg files so the
|
|
505
|
+
// browser treats them as SVG instead of generic XML. Inside HTML the <svg> element is
|
|
506
|
+
// already recognised by the browser, so the attribute is dead weight.
|
|
507
|
+
// https://github.com/mui/mui-public/pull/1321
|
|
508
|
+
message:
|
|
509
|
+
'Remove xmlns from inline <svg>. The attribute is redundant in HTML and adds unnecessary bytes.',
|
|
510
|
+
selector: 'JSXOpeningElement[name.name="svg"] > JSXAttribute[name.name="xmlns"]',
|
|
511
|
+
},
|
|
502
512
|
...restrictedSyntaxRules,
|
|
503
513
|
],
|
|
504
514
|
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import mochaPlugin from 'eslint-plugin-mocha';
|
|
2
2
|
import vitestPlugin from '@vitest/eslint-plugin';
|
|
3
3
|
import testingLibrary from 'eslint-plugin-testing-library';
|
|
4
|
-
|
|
4
|
+
// TODO: change back to 'eslint/config' once https://github.com/eslint/rewrite/issues/425 is fixed
|
|
5
|
+
import { defineConfig } from '@eslint/config-helpers';
|
|
5
6
|
import globals from 'globals';
|
|
6
7
|
import * as tseslint from 'typescript-eslint';
|
|
7
8
|
import { EXTENSION_TS } from './extensions.mjs';
|
package/src/untyped-plugins.d.ts
CHANGED
|
@@ -13,77 +13,77 @@ declare module 'eslint-config-airbnb' {
|
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
declare module 'eslint-config-airbnb-base/rules/best-practices' {
|
|
16
|
-
import { Linter } from 'eslint';
|
|
16
|
+
import { type Linter } from 'eslint';
|
|
17
17
|
|
|
18
18
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
19
19
|
export default config;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
declare module 'eslint-config-airbnb-base/rules/errors' {
|
|
23
|
-
import { Linter } from 'eslint';
|
|
23
|
+
import { type Linter } from 'eslint';
|
|
24
24
|
|
|
25
25
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
26
26
|
export default config;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
declare module 'eslint-config-airbnb-base/rules/es6' {
|
|
30
|
-
import { Linter } from 'eslint';
|
|
30
|
+
import { type Linter } from 'eslint';
|
|
31
31
|
|
|
32
32
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
33
33
|
export default config;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
declare module 'eslint-config-airbnb-base/rules/imports' {
|
|
37
|
-
import { Linter } from 'eslint';
|
|
37
|
+
import { type Linter } from 'eslint';
|
|
38
38
|
|
|
39
39
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
40
40
|
export default config;
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
declare module 'eslint-config-airbnb-base/rules/node' {
|
|
44
|
-
import { Linter } from 'eslint';
|
|
44
|
+
import { type Linter } from 'eslint';
|
|
45
45
|
|
|
46
46
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
47
47
|
export default config;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
declare module 'eslint-config-airbnb-base/rules/strict' {
|
|
51
|
-
import { Linter } from 'eslint';
|
|
51
|
+
import { type Linter } from 'eslint';
|
|
52
52
|
|
|
53
53
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
54
54
|
export default config;
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
declare module 'eslint-config-airbnb-base/rules/style' {
|
|
58
|
-
import { Linter } from 'eslint';
|
|
58
|
+
import { type Linter } from 'eslint';
|
|
59
59
|
|
|
60
60
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
61
61
|
export default config;
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
declare module 'eslint-config-airbnb-base/rules/variables' {
|
|
65
|
-
import { Linter } from 'eslint';
|
|
65
|
+
import { type Linter } from 'eslint';
|
|
66
66
|
|
|
67
67
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
68
68
|
export default config;
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
declare module 'eslint-config-airbnb/rules/react' {
|
|
72
|
-
import { Linter } from 'eslint';
|
|
72
|
+
import { type Linter } from 'eslint';
|
|
73
73
|
|
|
74
74
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
75
75
|
export default config;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
declare module 'eslint-config-airbnb/rules/react-a11y' {
|
|
79
|
-
import { Linter } from 'eslint';
|
|
79
|
+
import { type Linter } from 'eslint';
|
|
80
80
|
|
|
81
81
|
declare const config: Omit<Linter.LegacyConfig, 'extends' | 'plugins'>;
|
|
82
82
|
export default config;
|
|
83
83
|
}
|
|
84
84
|
|
|
85
85
|
declare module '@next/eslint-plugin-next' {
|
|
86
|
-
import { Linter } from 'eslint';
|
|
86
|
+
import { type Linter } from 'eslint';
|
|
87
87
|
|
|
88
88
|
interface NextEslintPluginConfig extends Linter.LegacyConfig {
|
|
89
89
|
flatConfig: {
|