Skip to:
Content

BuddyPress.org

Opened 8 years ago

Closed 8 years ago

Last modified 5 years ago

#5613 closed defect (bug) (fixed)

fix javascript to pass jshitn

Reported by: DJPaul Owned by: djpaul
Milestone: 2.1 Priority: normal
Severity: normal Version:
Component: Core Keywords:
Cc:

Description

In #5160, we've recently adopted a Grunt build process. Part of that process checks for well-written Javascript using the jshint library (see the .jshintrc file in the root of trunk for its config file). It's no surprise that some of our Javascript is pretty old, and it's causing a lot of failures in jshint.

This ticket is to cover a series of commits to get jshint to pass. I will not be testing the majority of these changes due to the volume, but as we've not even formally started the 2.1 cycle, we have lots of time to capture any breakage during 2.1's development cycle and test periods.

Change History (6)

#1 @djpaul
8 years ago

In 8377:

Update jshintrc for a common global we reference.

See #5613

#2 @djpaul
8 years ago

In 8378:

Javascript: first pass at improvements for jshint

See #5613

#3 @djpaul
8 years ago

In 8379:

Templates: remove the easing plugin

The easing library we were using (in only two places) is a sizeable
chunk of code that would need a reasonable amount of modification to
bring up to WP standards.

Instead, I’ve decided to remove it and just use the ‘swing’ easing
type, which comes bundled with jQuery.

See #5613

#4 @djpaul
8 years ago

  • Owner set to djpaul
  • Resolution set to fixed
  • Status changed from new to closed

In 8380:

Grunt: exclude BP-Default and BP-Legacy from jshint

These JS files contains a lot of legacy JS, requiring a lot of effort
to bring up to standards. It’s better to do that incrementally as part
of template improvements, rather than just to make jshint happy. For
now, let’s exclude these from further jshint checks.

Fixes #5613, see also #5160

#5 @johnjamesjacoby
7 years ago

  • Component changed from Component - Any/All to Tools - Code Improvement

#6 @DJPaul
5 years ago

  • Component changed from Tools - Code Improvement to Core
Note: See TracTickets for help on using tickets.