Add guide for adding a new service#89
Merged
edwardhorsford merged 3 commits intomainfrom Mar 27, 2025
Merged
Conversation
frankieroberto
approved these changes
Mar 27, 2025
| * create a `your-service-name.json` file within `app/posts/` that adds the eleventyNavigation parent name as the name of your service (copy an existing example) | ||
| * create a Markdown file in `app/posts/`, for example `app/posts/your-service-name.md`. Copy an existing example and update any references to match your service. | ||
| * update `eleventy.config.js` to create a new 'collection' for your service (copy one of the existing examples) | ||
| * update `app/_layouts/_product.njk` to list your new service in the sections variable |
Collaborator
There was a problem hiding this comment.
Suggested change
| * update `app/_layouts/_product.njk` to list your new service in the sections variable | |
| * update `app/_layouts/_product.njk` to list your new service in the `sections` variable |
jolumley-nhs
approved these changes
Mar 27, 2025
Collaborator
jolumley-nhs
left a comment
There was a problem hiding this comment.
Looks good - steps are all correct :)
Co-authored-by: Frankie Roberto <frankie.roberto1@nhs.net>
Contributor
LeeGathercole
left a comment
There was a problem hiding this comment.
Might be worth adding how the folders are structured under the posts and also how you reference images from a post to the image. I'd be a bit more explicit in the config, because
eleventyConfig.addCollection("your-service-name", (collection) => {
return collection.getFilteredByGlob(
"app/posts/your-service-name/**/*.md"
);
});
{ title: "Screening", services: [
"Bowel screening",
"Explore team",
"Manage breast screening",
"Manage your screening",
"Your service name"
] },
Not sure if it's old man eye-sight, but I struggled to find it
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.