mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-10-31 01:00:47 +08:00
[eslint] Enforce semis
This commit is contained in:
+15
-1
@@ -23,8 +23,22 @@ module.exports = {
|
||||
}
|
||||
],
|
||||
rules: {
|
||||
indent: ["error", 2, { "SwitchCase": 1 }],
|
||||
semi: "off", // We use the typescript-specific rule as it's more accurate.
|
||||
"@typescript-eslint/no-explicit-any": "off",
|
||||
indent: ["error", 2, { "SwitchCase": 1 }]
|
||||
"@typescript-eslint/semi": ["error"],
|
||||
"@typescript-eslint/member-delimiter-style": [
|
||||
"warn", {
|
||||
"multiline": {
|
||||
"delimiter": "semi",
|
||||
"requireLast": true,
|
||||
},
|
||||
"singleline": {
|
||||
"delimiter": "semi",
|
||||
"requireLast": false,
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
settings: {
|
||||
"svelte3/typescript": true,
|
||||
|
||||
+5
-5
@@ -1,10 +1,10 @@
|
||||
<script context="module" lang="typescript">
|
||||
export interface Field {
|
||||
name: string
|
||||
value: string | null
|
||||
label?: string
|
||||
placeholder?: string
|
||||
editable: boolean
|
||||
name: string;
|
||||
value: string | null;
|
||||
label?: string;
|
||||
placeholder?: string;
|
||||
editable: boolean;
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
<script lang="typescript">
|
||||
import { createEventDispatcher } from 'svelte';
|
||||
|
||||
export let options: { label: string, value: string }[];
|
||||
export let options: { label: string; value: string }[];
|
||||
export let name: string;
|
||||
export let selected = "";
|
||||
export let disabled = false;
|
||||
|
||||
@@ -29,8 +29,8 @@ const GetOrgs = `
|
||||
`;
|
||||
|
||||
export class Org {
|
||||
address: string
|
||||
owner: string
|
||||
address: string;
|
||||
owner: string;
|
||||
|
||||
constructor(address: string, owner: string) {
|
||||
assert(ethers.utils.isAddress(address), "address must be valid");
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
type State =
|
||||
{ status: Status.Loading }
|
||||
| { status: Status.Loaded }
|
||||
| { status: Status.Error, error: string };
|
||||
| { status: Status.Error; error: string };
|
||||
|
||||
export let project: proj.Project;
|
||||
export let config: Config;
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
let error: Error | null = null;
|
||||
let registrationOwner = owner || session.address;
|
||||
|
||||
const view = () => navigate(`/registrations/${subdomain}`)
|
||||
const view = () => navigate(`/registrations/${subdomain}`);
|
||||
|
||||
onMount(async () => {
|
||||
try {
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
{ status: Status.Signing }
|
||||
| { status: Status.Pending }
|
||||
| { status: Status.Success }
|
||||
| { status: Status.Failed, error: string };
|
||||
| { status: Status.Failed; error: string };
|
||||
|
||||
export let subdomain: string;
|
||||
export let config: Config;
|
||||
|
||||
@@ -27,8 +27,8 @@
|
||||
type State =
|
||||
{ status: Status.Loading }
|
||||
| { status: Status.NotFound }
|
||||
| { status: Status.Found, registration: Registration }
|
||||
| { status: Status.Failed, error: string };
|
||||
| { status: Status.Found; registration: Registration }
|
||||
| { status: Status.Failed; error: string };
|
||||
|
||||
export let subdomain: string;
|
||||
export let config: Config;
|
||||
@@ -74,7 +74,7 @@
|
||||
.filter(r => r.editable && r.value !== null)
|
||||
.map(f => {
|
||||
assert(f.value !== null);
|
||||
return { name: f.name, value: f.value }
|
||||
return { name: f.name, value: f.value };
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@ export class Config {
|
||||
provider: ethers.providers.JsonRpcProvider;
|
||||
signer: ethers.Signer & TypedDataSigner | null;
|
||||
safe: { api: string | null; viewer: string | null };
|
||||
abi: { [contract: string]: string[] }
|
||||
abi: { [contract: string]: string[] };
|
||||
seed: { api: string | null };
|
||||
tokens: string[];
|
||||
|
||||
|
||||
+1
-1
@@ -101,7 +101,7 @@ export async function getReadme(
|
||||
}
|
||||
|
||||
export function path(
|
||||
opts: { urn: string, org?: string, commit?: string, path?: string }
|
||||
opts: { urn: string; org?: string; commit?: string; path?: string }
|
||||
): string {
|
||||
const { urn, org, commit, path } = opts;
|
||||
const result = [];
|
||||
|
||||
Reference in New Issue
Block a user