don't fail check-param-names on destructuring in arguments - fixes #90#92
Closed
AlexanderZeilmann wants to merge 2 commits intojscs-dev:masterfrom
AlexanderZeilmann:master
Closed
don't fail check-param-names on destructuring in arguments - fixes #90#92AlexanderZeilmann wants to merge 2 commits intojscs-dev:masterfrom AlexanderZeilmann:master
AlexanderZeilmann wants to merge 2 commits intojscs-dev:masterfrom
AlexanderZeilmann:master
Conversation
Member
|
👍 I like it ;-) Thanks for contribution! I don't like this part of code at all. But this PR is pretty fine. |
Contributor
Author
|
Sorry for the delay, I was really busy :-/ I inserted/removed the lines. Furthermore I added support for fake parameter names, i.e. this example is now checked properly: /**
* My cool function.
*
* @param {Object} fakeName - An object.
* @param {string} fakeName.prop1 - Property 1.
* @param {string} fakeName.prop2 - Property 2.
*/
var fn = function ({prop1, prop2}) {
// Do something with prop1 and prop2
} |
Member
|
Oh, wow. Looks great ;-) I'm gonna merge this soon after some works. |
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.
Here is a first stab at fixing #90.
I had to create a new
describeblock in the tests, since the code which should be tested requires theesnextflag for jscs.Let me know what you think :-)