[buddypress-trac] [BuddyPress Trac] #9174: WPCS improvements for 15.0

buddypress-trac noreply at wordpress.org
Fri Jun 14 00:43:43 UTC 2024


#9174: WPCS improvements for 15.0
-------------------------+--------------------------
 Reporter:  espellcaste  |       Owner:  espellcaste
     Type:  task         |      Status:  assigned
 Priority:  normal       |   Milestone:  Up Next
Component:  Core         |     Version:
 Severity:  normal       |  Resolution:
 Keywords:               |
-------------------------+--------------------------

Comment (by espellcaste):

 > For those, I opted just to use "object" rather than the exact class
 names, because they're lengthy & ugly & make the docs more difficult to
 read. Feel free to override that decision later!

 I'm not opposed to this change but two arguments **for** adding the object
 class is IDE support (intelephense) and it makes more clearer about its
 value.

 In a IDE, like vscode, one can't go to that particular class anymore,
 since it is an anonymous `object`. One can't also tell what's the object
 real class, which properties this object support, if it does.

 Essentially, one loses intelephense support, which is helpful while
 developing and we would be documenting the variable's true value.

 If the `$global` value accepts both an anonymous `object` and
 `BP_Optouts_List_Table`, I'd advocate adding both there.

 > docs more difficult to read

 I'd argue it makes it lenthy, not difficult to read. But I'd accept this
 is just my opinion.

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/9174#comment:3>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list