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

Add stringify method to mirror parse #214

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

blakeembrey
Copy link
Member

Part of the work from #200, adding methods that mirror the existing methods so someone can easily understand parse/stringify and (in another PR) serialize/deserialize.

@wesleytodd
Copy link
Member

I think it would help if we had more documentation on this, maybe a description for the PR to clarify? The code looks like the goal is to take the output from cookie.parse and turn it back into a cookie header string? And I assume by the comment about "and in another pr seralize/desearlize" that there will be a follow up PR to add deseralize to parse set-cookie headers?

@blakeembrey
Copy link
Member Author

Yes.

@wesleytodd
Copy link
Member

Sorry, to which question?

@blakeembrey
Copy link
Member Author

Yes to all of them.

@@ -169,7 +169,7 @@ export interface StringifyOptions {
}

/**
* Stringify a set of cookies into a `Cookie` header string.
* Stringifies an object into a HTTP `Cookie` header.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* Stringifies an object into a HTTP `Cookie` header.
* Stringifies an object into an HTTP `Cookie` header.

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.

3 participants