mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-22 02:27:43 +00:00
Enable eslint rule quote-props (#1795)
## Description: Enable eslint rule `quote-props` ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced
This commit is contained in:
+11
-2
@@ -81,8 +81,8 @@ export default [
|
||||
"@typescript-eslint/prefer-includes": "error",
|
||||
"@typescript-eslint/prefer-literal-enum-member": "error",
|
||||
"@typescript-eslint/prefer-nullish-coalescing": "error",
|
||||
eqeqeq: "error",
|
||||
indent: "off", // @stylistic/ts/indent
|
||||
"eqeqeq": "error",
|
||||
"indent": "off", // @stylistic/ts/indent
|
||||
"sort-keys": "error",
|
||||
// "@typescript-eslint/no-unsafe-argument": "error", // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1780
|
||||
// "@typescript-eslint/no-unsafe-assignment": "error", // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1781
|
||||
@@ -90,13 +90,22 @@ export default [
|
||||
// "@typescript-eslint/no-unused-vars": ["error", { argsIgnorePattern: "^_" }], // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1784
|
||||
"@typescript-eslint/no-unused-vars": "off",
|
||||
"@typescript-eslint/prefer-for-of": "error",
|
||||
"array-bracket-newline": ["error", "consistent"],
|
||||
"array-element-newline": ["error", "consistent"],
|
||||
"arrow-parens": ["error", "always"],
|
||||
"comma-dangle": ["error", "always-multiline"],
|
||||
"function-call-argument-newline": ["error", "consistent"],
|
||||
"max-depth": ["error", { max: 5 }],
|
||||
// "max-len": ["error", { code: 120 }], // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1785
|
||||
"max-lines": ["error", { max: 1065, skipBlankLines: true, skipComments: true }],
|
||||
"max-lines-per-function": ["error", { max: 561 }],
|
||||
"object-curly-newline": ["error", { multiline: true, consistent: true }],
|
||||
"object-property-newline": ["error", { allowAllPropertiesOnSameLine: true }],
|
||||
"no-loss-of-precision": "error",
|
||||
"no-multi-spaces": "error",
|
||||
// "no-undef": "error", // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1786
|
||||
"no-unused-vars": "off", // @typescript-eslint/no-unused-vars
|
||||
"quote-props": ["error", "consistent-as-needed"],
|
||||
// 'sort-imports': 'error', // TODO: Enable this rule, https://github.com/openfrontio/OpenFrontIO/issues/1787
|
||||
"space-infix-ops": "off",
|
||||
},
|
||||
|
||||
@@ -41,7 +41,7 @@ export async function handlePurchase(priceId: string) {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
authorization: getAuthHeader(),
|
||||
"authorization": getAuthHeader(),
|
||||
},
|
||||
body: JSON.stringify({
|
||||
priceId: priceId,
|
||||
|
||||
@@ -1,16 +1,14 @@
|
||||
import { Cosmetics } from "./CosmeticSchemas";
|
||||
|
||||
const ANIMATION_DURATIONS: Record<string, number> = {
|
||||
rainbow: 4000,
|
||||
/* eslint-disable sort-keys */
|
||||
"bright-rainbow": 4000,
|
||||
"copper-glow": 3000,
|
||||
"silver-glow": 3000,
|
||||
"gold-glow": 3000,
|
||||
neon: 3000,
|
||||
lava: 6000,
|
||||
/* eslint-enable sort-keys */
|
||||
water: 6200,
|
||||
"lava": 6000,
|
||||
"neon": 3000,
|
||||
"rainbow": 4000,
|
||||
"silver-glow": 3000,
|
||||
"water": 6200,
|
||||
};
|
||||
|
||||
// TODO: Pass in cosmetics as a parameter when
|
||||
|
||||
@@ -69,7 +69,7 @@ export class Cloudflare {
|
||||
const response = await fetch(url, {
|
||||
body: data ? JSON.stringify(data) : undefined,
|
||||
headers: {
|
||||
Authorization: `Bearer ${this.apiToken}`,
|
||||
"Authorization": `Bearer ${this.apiToken}`,
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
method,
|
||||
@@ -184,7 +184,7 @@ export class Cloudflare {
|
||||
|
||||
const tunnelConfig: CloudflaredConfig = {
|
||||
"credentials-file": this.credsPath,
|
||||
ingress: [
|
||||
"ingress": [
|
||||
...Array.from(subdomainToService.entries()).map(
|
||||
([subdomain, service]) => ({
|
||||
hostname: `${subdomain}.${domain}`,
|
||||
@@ -195,7 +195,7 @@ export class Cloudflare {
|
||||
service: "http_status:404",
|
||||
},
|
||||
],
|
||||
tunnel: tunnelId,
|
||||
"tunnel": tunnelId,
|
||||
};
|
||||
|
||||
// Write config file
|
||||
|
||||
Reference in New Issue
Block a user