Skip to content

Commit 5ca4563

Browse files
authored
chore(general): fixes to config, workflows, linting and link checker (#1073)
2 parents 5cd63c8 + d133c37 commit 5ca4563

38 files changed

+717
-623
lines changed

.eslintrc.js

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,33 @@ module.exports = {
88
extends: [
99
"eslint:recommended",
1010
"plugin:@typescript-eslint/recommended",
11-
"prettier",
11+
"plugin:prettier/recommended",
1212
"plugin:@docusaurus/recommended",
1313
],
1414
parser: "@typescript-eslint/parser",
1515
parserOptions: {
1616
ecmaVersion: "latest",
1717
sourceType: "module",
1818
},
19-
plugins: ["@typescript-eslint", "prettier"],
19+
plugins: ["@typescript-eslint"],
2020
rules: {
21-
"prettier/prettier": [2],
21+
"prettier/prettier": "error",
22+
"@typescript-eslint/no-unused-vars": ["error", { argsIgnorePattern: "^_" }],
23+
"@typescript-eslint/consistent-type-imports": [
24+
"warn",
25+
{ prefer: "type-imports" },
26+
],
2227
},
28+
overrides: [
29+
{
30+
files: [
31+
"*.config.js",
32+
"*.config.ts",
33+
"docusaurus.config.*",
34+
"sidebars.*",
35+
],
36+
env: { node: true },
37+
rules: { "@typescript-eslint/no-var-requires": "off" },
38+
},
39+
],
2340
};

.github/workflows/check-external-links.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ jobs:
1212
check-external-links:
1313
runs-on: ubuntu-latest
1414
permissions:
15-
issues: write
15+
contents: read
16+
pull-requests: write
1617
steps:
1718
- uses: actions/checkout@v6
1819
- name: Restore lychee cache
@@ -24,16 +25,16 @@ jobs:
2425
- name: Link Checker
2526
id: lychee
2627
uses: lycheeverse/lychee-action@v2
28+
continue-on-error: true
2729
with:
2830
lycheeVersion: "latest"
2931
args: |
3032
--config lychee.toml
31-
.
32-
fail: true
33+
docs
3334
env:
3435
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3536
- name: Comment on PR if broken links found
36-
if: steps.lychee.outputs.exit_code != 0
37+
if: ${{ always() && steps.lychee.outputs.exit_code != 0 }}
3738
uses: thollander/actions-comment-pull-request@v3
3839
with:
3940
message: |
@@ -47,3 +48,6 @@ jobs:
4748
</details>
4849
env:
4950
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
51+
- name: Fail if broken links found
52+
if: ${{ steps.lychee.outputs.exit_code != 0 }}
53+
run: exit 1

docs/fassets/developer-guides/usdt0-fxrp-swap.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ Before starting, make sure you have:
2626

2727
## Required Addresses on Flare Mainnet
2828

29-
- V3 SwapRouter (SparkDEX): [0x8a1E35F5c98C4E85B36B7B253222eE17773b2781](https://flarescan.com/address/0x8a1E35F5c98C4E85B36B7B253222eE17773b2781/contract/14/code).
30-
- USDT0: [0xe7cd86e13AC4309349F30B3435a9d337750fC82D](https://flarescan.com/address/0xe7cd86e13AC4309349F30B3435a9d337750fC82D).
29+
- V3 SwapRouter (SparkDEX): [0x8a1E35F5c98C4E85B36B7B253222eE17773b2781](https://flare-explorer.flare.network/address/0x8a1E35F5c98C4E85B36B7B253222eE17773b2781?tab=contract).
30+
- USDT0: [0xe7cd86e13AC4309349F30B3435a9d337750fC82D](https://flare-explorer.flare.network/address/0xe7cd86e13AC4309349F30B3435a9d337750fC82D).
3131
- FXRP: [resolved dynamically from the Asset Manager](/fassets/developer-guides/fassets-fxrp-address).
3232

3333
## Solidity Uniswap V3 Wrapper Contract

docs/run-node/2-from-source.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Make sure to check the [hardware requirements](/run-node/system-requirements) be
2020
- [git](https://git-scm.com/install/)
2121
- [GCC](https://gcc.gnu.org/install/)
2222
- [jq](https://stedolan.github.io/jq/download/)
23-
- [rsync](https://rsync.samba.org/download.html)
23+
- [rsync](https://github.com/RsyncProject/rsync)
2424
- [cURL](https://curl.se/download.html)
2525
- [Ubuntu](https://ubuntu.com) (`>=24.10`)
2626

docs/support/terminology.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ A consensus mechanism in which token holders vote for validators to secure the n
4545

4646
Enshrining involves incorporating essential middleware components directly into the core protocol of a blockchain network. For a component to be considered enshrined, it **must** require a network hard-fork to be altered (refer to Vitalik's article on [enshrinement](https://vitalik.eth.limo/general/2023/09/30/enshrinement.html)).
4747

48-
Enshrining can be seen as a stronger form of restaking, a concept popularized by protocols like [EigenLayer](https://docs.eigencloud.xyz/eigenlayer/concepts/eigenlayer-overview). Unlike restaking, where only a fraction of the network stake is used to secure middleware, enshrining leverages the entire network stake.
48+
Enshrining can be seen as a stronger form of restaking, a concept popularized by protocols like [EigenLayer](https://docs.eigencloud.xyz). Unlike restaking, where only a fraction of the network stake is used to secure middleware, enshrining leverages the entire network stake.
4949

5050
An enshrined oracle is an oracle that is integrated into the core protocol of a blockchain network. These oracles inherit the full security of the network, meaning that compromising the safety or liveness of the oracle would necessitate compromising the entire network.
5151

docusaurus.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ const config: Config = {
242242
indexDocs: true,
243243
indexPages: true,
244244
indexBlog: false,
245+
hashed: true,
245246
docsRouteBasePath: "/",
246247
},
247248
],

examples/developer-hub-javascript/GaslessApp.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React, { useState } from "react";
2-
import { ethers, Eip1193Provider } from "ethers";
2+
import { ethers, type Eip1193Provider } from "ethers";
33
import USD0Abi from "./USD0.json";
44
import Heading from "@theme/Heading";
55

examples/developer-hub-javascript/PriceVerification.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { artifacts, web3, run } from "hardhat";
2-
import {
2+
import type {
33
PriceVerifierCustomFeedInstance,
44
IRelayInstance,
55
} from "../../typechain-types";

examples/developer-hub-javascript/api3Example.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { artifacts, run, web3 } from "hardhat";
2-
import { PriceGuesserInstance } from "../../typechain-types";
2+
import type { PriceGuesserInstance } from "../../typechain-types";
33

44
// --- Configuration ---
55
const PriceGuesser: PriceGuesserInstance = artifacts.require("PriceGuesser");

examples/developer-hub-javascript/bandExample.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { artifacts, network, run, web3 } from "hardhat";
2-
import { PriceTriggeredSafeInstance } from "../../typechain-types";
2+
import type { PriceTriggeredSafeInstance } from "../../typechain-types";
33

44
// --- Configuration ---
55
const PriceTriggeredSafe: PriceTriggeredSafeInstance =

0 commit comments

Comments
 (0)