-
-
Notifications
You must be signed in to change notification settings - Fork 386
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
Add ability to insert a value specified in config into the document #4578
Comments
We probably need some kind of new template syntax for that. This feels very much like something a custom element should handle. we might want to check if we do this in some other way already |
I was hoping One thing we should consider is how complex the expressions within that are allowed to be, and if there are any injection risks: where I just wrote |
Is your feature request related to a problem? Please describe.
I'd really like to be able to include a link to the document's GitHub repo in the document itself, not just in the header. This information is already part of the Respec config, so I would like to be able to re-use it rather than duplicate it. I found a way to insert Respec config using a post processing script, but it feels as though there ought to be a better way.
I'd generalise this to any Respec config value, not just the repo URL.
Describe the solution you'd like
I'd like to be able to include some kind of macro, maybe nunjucks-style, that inserts values from javascript into the HTML document using a common syntax in the HTML itself.
Additional context
The reason I'm inserting a link to the GitHub repo in this case is because I want to put it into the Registry Definition instructions for requesting a change to an inline Registry Table, and those instructions include "raise an issue on the repo", effectively.
See also spec-prod email thread at https://lists.w3.org/Archives/Public/spec-prod/2023OctDec/0003.html
Describe any alternatives you've considered
Hack that I consider ugly, to do this now, at https://github.com/w3c/dapt/blob/72dae1c652b6ce5e74a7fe4fcc19b49dfaf86fb9/index.html#L8-12 - I then add a specific class value to all the
<a>
elements whosehref
attribute I want to replace, and reference this function in thepostProcess
array in the Respec config.Can you or your organization fund the work or help with development?
ReSpec is a community maintained project, meaning it doesn't have any dedicated staff or funding.
There are three options to get your feature implemented. You can:
Funding pays for the feature development, testing, documentation, server costs, etc. We have an open collective where development costs are tracked and shared. Please see our Open Collective.
The text was updated successfully, but these errors were encountered: