javascripts/govuk/show-hide-content.js
function getEventSelectorsForRadioGroups () {
      var radioGroups = []

      // Build an array of radio group selectors
      return $(selectors.radio).map(function () {
        var groupName = $(this).attr('name')

        if ($.inArray(groupName, radioGroups) === -1) {
          radioGroups.push(groupName)
          return 'input[type="radio"][name="' + $(this).attr('name') + '"]'
        }
        return null
      })
    }
function getEventSelectorsForRadioGroups () {
      var radioGroups = []

      // Build an array of radio group selectors
      return $(selectors.radio).map(function () {
        var groupName = $(this).attr('name')

        if ($.inArray(groupName, radioGroups) === -1) {
          radioGroups.push(groupName)
          return 'input[type="radio"][name="' + $(this).attr('name') + '"]'
        }
        return null
      })
    }
function getEventSelectorsForRadioGroups ( ) { var radioGroups = [ ] // Build an array of radio group selectors return $ ( selectors . radio ) . map ( function ( ) { var groupName = $ ( this ) . attr ( 'name' ) if ( $ . inArray ( groupName , radioGroups ) === - 1 ) { radioGroups . push ( groupName ) return 'input[type="radio"][name="' + $ ( this ) . attr ( 'name' ) + '"]' } return null } ) }
Get event selectors for all radio groups
Get event selectors for all radio groups