Skip to content
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

Consolidate Code Examples Using Hugo Shortcodes #73

Open
pabloariasmora opened this issue Dec 28, 2024 · 0 comments
Open

Consolidate Code Examples Using Hugo Shortcodes #73

pabloariasmora opened this issue Dec 28, 2024 · 0 comments

Comments

@pabloariasmora
Copy link

Description:
Currently, the documentation includes embedded code examples directly within the markdown files. To improve maintainability and consistency, it would be beneficial to consolidate code examples using Hugo shortcodes. This approach allows code examples to be included from separate files, making it easier to update and manage them.

Proposed Solution:

  • Use Hugo's readFile shortcode to include code examples from separate files.
  • Organize code examples in a dedicated directory within the repository.
  • Update the documentation to reference the code examples using the readFile shortcode.

Benefits:

  • Improved maintainability: Code examples can be updated independently of the documentation.
  • Consistency: Ensures that code examples are consistent across different sections of the documentation.
  • Clarity: Separates content from code, making the documentation easier to read and navigate.

For more details on how to implement this, please refer to this guide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant