felixarntz/theme-boilerplate

View on GitHub
assets/src/js/fonts.customize-controls.js

Summary

Maintainability
B
5 hrs
Test Coverage

Function initializeFontFamilySelect has 90 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        initializeFontFamilySelect: function( $element ) {
            const selectData   = {};
            const includedData = {};
            const excludedData = {};
            const settingValue = this.setting.get();
Severity: Major
Found in assets/src/js/fonts.customize-controls.js - About 3 hrs to fix

    Function ready has 36 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            ready: function() {
                const value         = this.setting.get();
                const $familySelect = this.container.find( '[data-setting-property="family"]' );
                const $weightSelect = this.container.find( '[data-setting-property="weight"]' );
                const $sizeInput    = this.container.find( '[data-setting-property="size"]' );
    Severity: Minor
    Found in assets/src/js/fonts.customize-controls.js - About 1 hr to fix

      There are no issues that match your filters.

      Category
      Status