Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Update form_collections.rst#3157

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
weaverryan merged 2 commits intosymfony:2.0fromattardi:patch-1
Nov 12, 2013
Merged

Update form_collections.rst#3157

weaverryan merged 2 commits intosymfony:2.0fromattardi:patch-1
Nov 12, 2013

Conversation

attardi
Copy link
Contributor

The assignment to collectionHolder must be done within jQuery ready function, or else it will be null.
BTW, the variables in JavaScript do not need the $, which is confusing since in jQuery $ has a special meaning.

The assignment to collectionHolder must be done within jQuery ready function, or else it will be null.BTW, the variables in JavaScript do not need the $, which is confusing since in jQuery $ has a special meaning.
@wouterj
Copy link
Member

I always use $ to indicate it's a jQuery object, but if it's confusing I agree with removing them

@wouterj
Copy link
Member

so 👍

(could you please include thePR template into your PR description?)

@attardi
Copy link
ContributorAuthor

Actually the variable collectionHolder should be assigned within the jQuery ready function, but declared outside, since it is used in other functions as well.

@weaverryan
Copy link
Member

Hi Giuseppe!

It's subjective, but I don't agree with removing the$ in front of the variables. I believe it's a semi-standard -http://stackoverflow.com/questions/205853/why-would-a-javascript-variable-start-with-a-dollar-sign#answer-553734. We'll see what others think. But you're right about the variable move :).

Cheers!

@bicpi
Copy link
Contributor

Using$ in front is also a best practice for me; at first glance you know what kind of variable it is.

@ggam
Copy link

ggam commentedNov 6, 2013

In case we keep the$ prefix, we can add a notice explaining its meaning.

@weaverryan
Copy link
Member

That sounds like a good suggestion to me.@attardi can you make the change to put the $ back and add a note about it?

Thanks!

@lyrixx
Copy link
Member

I used to prefix my jQuery object with$ too.

@attardi
Copy link
ContributorAuthor

On 11/9/2013 18:59, Ryan Weaver wrote:

That sounds like a good suggestion to me.@attardi
https://github.com/attardi can you make the change to put the $ back
and add a note about it?

Thanks!

I did it.
However github generated another branch when I tried to edit.
Then I closed and it yold me I had unmerged pull requests.
I am not sure I did the right thing.

-- Beppe

@wouterj
Copy link
Member

@attardi you should go to your repo, select the patch-1 branch and do the updates then.

The variable collectionHolder must be assigned inside the jQuery ready function, but must be declared outside, since it is used also in other functions.I have put back the '$' in front of names of variables having jQuery objects as values and for uniformity, also added it to collectionHolder.
@attardi
Copy link
ContributorAuthor

On 11/9/2013 19:47, Wouter J wrote:

@attardihttps://github.com/attardi you should go to your repo,
select the patch-1 branch and do the updates then.


Reply to this email directly or view it on GitHub
#3157 (comment).

Did it.
I changed the name of collectionHolder to $collectionHolder, because
that too is a jQuery variable.

-- Beppe

weaverryan added a commit that referenced this pull requestNov 12, 2013
@weaverryanweaverryan merged commitbb34344 intosymfony:2.0Nov 12, 2013
weaverryan added a commit that referenced this pull requestNov 12, 2013
@weaverryan
Copy link
Member

Thanks everyone! Small tweak at sha:ae5a6d2

Cheers!

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

6 participants
@attardi@wouterj@weaverryan@bicpi@ggam@lyrixx

[8]ページ先頭

©2009-2025 Movatter.jp