Skip to content

Add an HTML anchor <a> with the digest of the code example #1709

Closed
@ezimuel

Description

@ezimuel

This is a proposal to add an HTML anchor <a name="36818c6d9f434d387819c30bd9addb14"> with the digest of the code examples in the Elasticsearch Reference documentation.

anchor_example_digest

Right now, it's very difficult to find the location of a code example in the documentation. We have this alternatives_report.json file that contains all the console examples with page names and digests. We can find the documentation page where the example is present but we need to scroll manually and comparing the code content with the one reported on the page. Not that easy!

Having this HTML anchor based on the digest we can simplify all the process and share code examples in the Elasticsearch documentation with just a link, e.g. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html#36818c6d9f434d387819c30bd9addb14

I'm pretty sure that the digest is already managed by the script that converts Asciidoc to HTML. We need to add a <a name="digest-value"> before the code example.

CC @elastic/es-clients-core

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions