-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Docs: Code Snippets Reliability #1960
Comments
Summary
Investigation
Occurs during the fix-indent.ts process on the docs hub. Also appears to be a problem with the rust snippets. I believe this is due to regex replacement conflicting. For all projects, languages and coding format.
There is no syntax highlighting configured for
Incorrect
Variables not being detected. Potential solution:
tsBookVersions: (node: any) => {
return (
typeof node.value === 'string' &&
(node.value.includes('{{fuels}}') ||
node.value.includes('{{fuelCore}}') ||
node.value.includes('{{forc}}')
)
);
},
visit(newTree, '', (node: any, idx, parent) => {
if (conditions.tsBookVersions(node)) {
node.value = node.value
.replace('{{fuels}}', versions.FUELS)
.replace('{{fuelCore}}', versions.FUEL_CORE)
.replace('{{forc}}', versions.FORC);
}
...
})
There are 54 instances of |
Moving this back to Keeping my name on for follow up purposes 😄 |
Great job! Can't we close the issue as completed? 🙂 You did everything and created issues on the docs-hub repo for the remaining items. |
That sounds like a better idea 🥇 |
Closing due to all issues within |
Here are a few examples where the code snippets behave erratically:
// #import { BN, CoinQuantityLike, ScriptTransactionRequest }
We should probably be considering getting rid of
#context
tags if possible.The text was updated successfully, but these errors were encountered: