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

feat: Add function to validate an identifier #534

Closed
wants to merge 1 commit into from
Closed

Conversation

wraithgar
Copy link
Member

@wraithgar wraithgar commented Apr 5, 2023

Cleanup and linting of #351
Closes #350

Authored by @boxcee

@wraithgar wraithgar requested a review from a team as a code owner April 5, 2023 23:42
@wraithgar wraithgar requested review from nlf and removed request for a team April 5, 2023 23:42
@wraithgar wraithgar changed the title Pull/351 feat: Add function to validate an identifier Apr 5, 2023
functions/identifier.js Outdated Show resolved Hide resolved
Copy link
Contributor

@nlf nlf left a comment

Choose a reason for hiding this comment

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

the functionality here looks good. i do think the function name identifier is a little vague, but i don't have any alternatives to suggest so i'm going to approve this as-is

@wraithgar
Copy link
Member Author

the codebase calls this a prereleaseidentifier which is quite a mouthful

@ljharb
Copy link

ljharb commented Apr 10, 2023

The bin (which is user-exposed, unlike the codebase) calls it --preid - perhaps preID as short for preleaseIdentifier?

@wraithgar
Copy link
Member Author

Looking a little deeper at this, the impetus was #349 which this PR doesn't address. The line we've been using on these PRs is that if they were ready to go we could land them, but if they needed more work we'd close them and hope that folks who wanted the feature would revisit the work. I'm gonna close this in light of #349 which is the real bug to be fixed here.

@wraithgar wraithgar closed this Apr 10, 2023
@wraithgar wraithgar deleted the pull/351 branch April 10, 2023 18:21
@ljharb
Copy link

ljharb commented Apr 10, 2023

@wraithgar i have a local branch ready to fix #349 once this lands :-/

@wraithgar
Copy link
Member Author

Can you implement it without having to export a new function?

@ljharb
Copy link

ljharb commented Apr 10, 2023

Certainly I can, but then consumers won't have an easily accessible predicate function to help explain why they got null. What's the argument against adding this?

@boxcee
Copy link

boxcee commented Apr 14, 2023

As I understand the closing comment, this PR needs more work. I cannot see any requests to change anything though, except perhaps the naming.

@wraithgar
Copy link
Member Author

In rebasing old PRs the line was drawn at "is this ready" and since it didn't address the underlying issue and folks wanted to bikeshed the name it was deemed "not ready" and closed.

If there were someone actively making a new PR and responding to feedback it would likely be landed.

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.

[FEATURE] Function to check for validity of a prerelease identifier
5 participants