-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into sarah/lint
- Loading branch information
Showing
10 changed files
with
59 additions
and
13 deletions.
There are no files selected for viewing
Submodule fuel-indexer
updated
46 files
Submodule fuel-specs
updated
6 files
+1 −1 | src/SUMMARY.md | |
+1 −1 | src/fuel-vm/index.md | |
+19 −0 | src/tx-format/consensus_parameters.md | |
+0 −18 | src/tx-format/constants.md | |
+1 −1 | src/tx-format/index.md | |
+1 −0 | src/tx-format/transaction.md |
Submodule fuels-wallet
updated
231 files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import fs from 'fs'; | ||
import path from 'path'; | ||
|
||
const examplesPath = './docs/fuels-wallet/packages/docs/examples'; | ||
const latestExamplesPath = './docs/latest/fuels-wallet/packages/docs/examples'; | ||
|
||
const propToReplace = 'onPress'; | ||
const replacementProp = 'onClick'; | ||
|
||
const pattern = new RegExp(`\\b${propToReplace}\\s*=\\s*\\{([^}]+)\\}`, 'g'); | ||
|
||
function replaceInFile(filePath) { | ||
const content = fs.readFileSync(filePath, 'utf8'); | ||
const newContent = content.replace(pattern, `${replacementProp}={$1}`); | ||
fs.writeFileSync(filePath, newContent); | ||
} | ||
|
||
function processDirectory(directory) { | ||
const files = fs.readdirSync(directory); | ||
|
||
files.forEach((fileName) => { | ||
const filePath = path.join(directory, fileName); | ||
const stat = fs.statSync(filePath); | ||
|
||
if (stat.isDirectory()) { | ||
processDirectory(filePath); | ||
} else if (fileName.endsWith('.tsx')) { | ||
replaceInFile(filePath); | ||
} | ||
}); | ||
} | ||
|
||
processDirectory(examplesPath); | ||
processDirectory(latestExamplesPath); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters