original_string: public function renderField($field, $options = [])
      {
          $this->prepareVars();
  
          if (is_string($field)) {
              if (!isset($this->allFields[$field])) {
                  throw new ApplicationException(Lang::get(
                      'backend::lang.form.missing_definition',
                      compact('field')
                  ));
              }
  
              $field = $this->allFields[$field];
          }
  
          if (!isset($options['useContainer'])) {
              $options['useContainer'] = true;
          }
          $targetPartial = $options['useContainer'] ? 'field-container' : 'field';
  
          return $this->makePartial($targetPartial, ['field' => $field]);
      }
code: public function renderField($field, $options = [])
      {
          $this->prepareVars();
  
          if (is_string($field)) {
              if (!isset($this->allFields[$field])) {
                  throw new ApplicationException(Lang::get(
                      'backend::lang.form.missing_definition',
                      compact('field')
                  ));
              }
  
              $field = $this->allFields[$field];
          }
  
          if (!isset($options['useContainer'])) {
              $options['useContainer'] = true;
          }
          $targetPartial = $options['useContainer'] ? 'field-container' : 'field';
  
          return $this->makePartial($targetPartial, ['field' => $field]);
      }
code_tokens: public function renderField ( $ field , $ options = [ ] ) { $ this -> prepareVars ( ) ; if ( is_string ( $ field ) ) { if ( ! isset ( $ this -> allFields [ $ field ] ) ) { throw new ApplicationException ( Lang :: get ( 'backend::lang.form.missing_definition' , compact ( 'field' ) ) ) ; } $ field = $ this -> allFields [ $ field ] ; } if ( ! isset ( $ options [ 'useContainer' ] ) ) { $ options [ 'useContainer' ] = true ; } $ targetPartial = $ options [ 'useContainer' ] ? 'field-container' : 'field' ; return $ this -> makePartial ( $ targetPartial , [ 'field' => $ field ] ) ; }
docstring: Renders a single form field
  
  Options:
  - useContainer: Wrap the result in a container, used by AJAX. Default: true
  
  @param string|array $field The field name or definition
  @param array $options
  @return string|bool The rendered partial contents, or false if suppressing an exception
docstring_tokens: Renders a single form field