last(arg1) {
    let element = null;
      
    const getLastItemOfType = (parent, type) => {
      if ( typeof parent == 'object' && parent.constructor && parent.constructor.name.toLowerCase() == type.toLowerCase() )        
        element = parent;
      
      if ( typeof parent.content == 'function' && typeof parent.content() == 'object' && parent.content().constructor.name == 'Array' ) {
        parent.content().forEach((item) => {
          getLastItemOfType(item, type);
        });
      }
    };

    getLastItemOfType(this, arg1);
    
    return element;
  }
/**
   * Find last item of certain object type in contents.
   * @signature last(string) Get the last item of type (string) in contents
   * @return The last item of type (string) in contents
   */
Find last item of certain object type in contents.
@signature last(string) Get the last item of type (string) in contents
@return The last item of type (string) in contents
Find last item of certain object type in contents . @signature last ( string ) Get the last item of type ( string ) in contents @return The last item of type ( string ) in contents
last(arg1) {
    let element = null;
    const getLastItemOfType = (parent, type) => {
      if ( typeof parent == 'object' && parent.constructor && parent.constructor.name.toLowerCase() == type.toLowerCase() )        
        element = parent;
      if ( typeof parent.content == 'function' && typeof parent.content() == 'object' && parent.content().constructor.name == 'Array' ) {
        parent.content().forEach((item) => {
          getLastItemOfType(item, type);
        });
      }
    };
    getLastItemOfType(this, arg1);
    return element;
  }
last ( arg1 ) { let element = null ; const getLastItemOfType = ( parent , type ) => { if ( typeof parent == 'object' && parent . constructor && parent . constructor . name . toLowerCase ( ) == type . toLowerCase ( ) ) element = parent ; if ( typeof parent . content == 'function' && typeof parent . content ( ) == 'object' && parent . content ( ) . constructor . name == 'Array' ) { parent . content ( ) . forEach ( ( item ) => { getLastItemOfType ( item , type ) ; } ) ; } } ; getLastItemOfType ( this , arg1 ) ; return element ; }
Find last item of certain object type in contents.
Find last item of certain object type in contents .