Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(infra/biome): rule noDoubleEquals #7265

Merged
merged 2 commits into from
Jul 23, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
chore(infra/biome): rule noDoubleEquals
  • Loading branch information
shulaoda committed Jul 23, 2024
commit bc1b22610c64e0a98386a0f70d8a478476cebc29
3 changes: 3 additions & 0 deletions biome.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 50,9 @@
"useImportType": "error",
"useExportType": "error",
"useEnumInitializers": "error"
},
"suspicious": {
"noDoubleEquals": "error"
}
},
"ignore": [
Expand Down
3,458 changes: 1,729 additions & 1,729 deletions packages/rspack/etc/api.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/rspack/scripts/check-documentation-coverage.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 191,7 @@ function checkConfigsDocumentationCoverage() {
let level;
for (let j = 0; j < line.length; j ) {
if (level === undefined) {
if (line[j] != "#") {
if (line[j] !== "#") {
level = j;
}
} else {
Expand Down
4 changes: 2 additions & 2 deletions packages/rspack/src/config/adapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 178,8 @@ function getRawTsConfig(
return {
configFile,
referencesType:
references == "auto" ? "auto" : references ? "manual" : "disabled",
references: references == "auto" ? undefined : references
references === "auto" ? "auto" : references ? "manual" : "disabled",
references: references === "auto" ? undefined : references
};
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/build-npm.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 119,7 @@ for (const binding of bindings) {
platformArchABI
} = parseTriple(name.slice(9));
assert(
file.split(".")[1] == platformArchABI,
file.split(".")[1] === platformArchABI,
`Binding is not matched with triple (expected: rspack.${platformArchABI}.node, got: ${file})`
);

Expand Down
2 changes: 1 addition & 1 deletion scripts/meta/check_is_workspace_root.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 10,7 @@ try {
}
}
);
if (rootPkgJson.name != "monorepo") {
if (rootPkgJson.name !== "monorepo") {
throw new Error(`Unexpected cwd ${process.cwd()}`);
}
} catch (oldErr) {
Expand Down
2 changes: 1 addition & 1 deletion website/components/webpack-license.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 3,7 @@ import { useLang } from 'rspress/runtime';

const WebpackLicense: FC<{ from: string | string[] }> = ({ from }) => {
const links = Array.isArray(from) ? from : [from];
const isEn = useLang() == 'en';
const isEn = useLang() === 'en';
if (isEn) {
return (
<details>
Expand Down
2 changes: 1 addition & 1 deletion website/theme/components/Announcement/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 26,7 @@ export function Announcement() {
}}
>
<a
href={`${lang == 'en' ? '' : `/${lang}`}/misc/join-us.html`}
href={`${lang === 'en' ? '' : `/${lang}`}/misc/join-us.html`}
className="hover:underline text-gray-700 font-bold"
>
{t('recruit')}
Expand Down