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

Setup router api #1572

Merged
merged 2 commits into from
Sep 5, 2022
Merged

Setup router api #1572

merged 2 commits into from
Sep 5, 2022

Conversation

nataliecarey
Copy link
Contributor

Allowing the user to create a router.

We explored ideas around more fine grained control instead of providing router functionality but I've reconsidered and think that's better to grow over time alongside providing routers. We can deprecate the routers at a later date if we want to replace them with more fine grained methods.

@nataliecarey nataliecarey requested a review from a team September 1, 2022 15:31
@nataliecarey nataliecarey changed the base branch from main to v13 September 1, 2022 15:31
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-protot-setup-rout-frgzph September 1, 2022 15:31 Inactive
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-protot-setup-rout-frgzph September 1, 2022 20:59 Inactive
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-protot-setup-rout-frgzph September 1, 2022 21:21 Inactive
@nataliecarey
Copy link
Contributor Author

I think we can do better with the name of serveDirectory but I couldn't think of anything better while coding it.

@nataliecarey nataliecarey linked an issue Sep 2, 2022 that may be closed by this pull request
5 tasks
@lfdebrux
Copy link
Member

lfdebrux commented Sep 2, 2022

@natcarey changes make sense to me, would you mind updating the changelog in this PR?

@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-protot-setup-rout-frgzph September 2, 2022 08:09 Inactive
CHANGELOG.md Outdated
@@ -12,7 +12,7 @@
- Assets and Javascript are served from their location in the app folder rather than being copied to a public folder
- Generated assets are all inside .tmp
- The core prototype-kit files have been moved into the package
- The start script uses the new govuk-prototype-kit cli
- The start script uses the new uk-prototype-kit cli
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo - govuk

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@@ -1,6 +1,4 @@
const express = require('express')
const router = express.Router()
/* eslint-disable-next-line no-unused-vars */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there any way for users to not get these lines, as they probably don't need them and they are a bit daunting

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think we should look at the starter kit as a whole and look at this line as part of it.

Copy link
Contributor

@BenSurgisonGDS BenSurgisonGDS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just my comment about the name of the cli in the comment within the changelog, otherwise looks good.

CHANGELOG.md Outdated
@@ -12,7 +12,7 @@
- Assets and Javascript are served from their location in the app folder rather than being copied to a public folder
- Generated assets are all inside .tmp
- The core prototype-kit files have been moved into the package
- The start script uses the new govuk-prototype-kit cli
- The start script uses the new uk-prototype-kit cli
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has govuk-prototype-kit been changed to uk-prototype-kit by mistake?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Copy link
Contributor

@joelanman joelanman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good thanks!

@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-protot-setup-rout-frgzph September 5, 2022 10:05 Inactive
@nataliecarey nataliecarey merged commit d2ad384 into v13 Sep 5, 2022
@nataliecarey nataliecarey deleted the setup-router-api branch September 5, 2022 10:40
@lfdebrux lfdebrux mentioned this pull request Nov 17, 2022
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

Successfully merging this pull request may close these issues.

Create api for request handling
5 participants