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

rustdoc needs a way to specify HTML metadata for standalone docs #16178

Closed
brson opened this issue Aug 1, 2014 · 13 comments
Closed

rustdoc needs a way to specify HTML metadata for standalone docs #16178

brson opened this issue Aug 1, 2014 · 13 comments
Labels
C-feature-request Category: A feature request, i.e: not implemented / a PR. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@brson
Copy link
Contributor

brson commented Aug 1, 2014

The HTML meta tags for descriptions and keywords are both important for SEO. For library docs we can generate this information automatically, but not for standalone docs.

I've never seen any such markdown extension, though maybe Jekyll headers can do this. We may need to invent something.

cc #12466.

@brson brson added the A-rustdoc label Aug 1, 2014
@brson brson mentioned this issue Aug 1, 2014
6 tasks
@thehydroimpulse
Copy link
Contributor

I implemented a frontmatter module for rustdoc not too long ago. So you can specify arbitrary key->value pairs:

---
title: "Foobar"
description: "Foobar 123"
keywords: ["foo", "bar"]
---

# Header 1

blah blah

Not sure if that's what you're thinking of.

@brson
Copy link
Contributor Author

brson commented Aug 2, 2014

@thehydroimpulse Yes, that sounds exactly like what I need!

@thehydroimpulse
Copy link
Contributor

Cool, I'll extract it out into it's own PR.

@steveklabnik
Copy link
Member

That's sweet, though other frontmatter i've seen usually has ---s at both the top and bottom of it.

@thehydroimpulse
Copy link
Contributor

Oh yeah, there's also one at the top.

@steveklabnik
Copy link
Member

triage: no change

@edunham
Copy link
Member

edunham commented Aug 12, 2015

@thehydroimpulse Could you link the PR from this issue to make it easier to track?

@thehydroimpulse
Copy link
Contributor

@edunham It's a really old PR. #16374

@edunham
Copy link
Member

edunham commented Aug 12, 2015

aww, looks like it got stalled on insufficient time for cleanup. Thanks for the link!

@steveklabnik
Copy link
Member

Triage: no change.

@steveklabnik steveklabnik added T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. and removed T-tools labels May 18, 2017
@Mark-Simulacrum Mark-Simulacrum added the C-feature-request Category: A feature request, i.e: not implemented / a PR. label Jul 21, 2017
@steveklabnik
Copy link
Member

@rust-lang/rustdoc, are we interested in this feature?

@GuillaumeGomez
Copy link
Member

I can add it.

@GuillaumeGomez
Copy link
Member

Actually we can already add data in headers through --html-in-header option. Closing it then.

bors added a commit to rust-lang-ci/rust that referenced this issue Jan 3, 2024
fix: Fix span marking for builtin fn macros
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature-request Category: A feature request, i.e: not implemented / a PR. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

6 participants