Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface IAngularStatic

Hierarchy

  • IAngularStatic

Index

Properties

element

element: JQueryStatic

Wraps a raw DOM element or HTML string as a jQuery element.

If jQuery is available, angular.element is an alias for the jQuery function. If jQuery is not available, angular.element delegates to Angular's built-in subset of jQuery, called "jQuery lite" or "jqLite."

version

version: { codeName: string; dot: number; full: string; major: number; minor: number }

Type declaration

  • codeName: string
  • dot: number
  • full: string
  • major: number
  • minor: number

Methods

UNSAFE_restoreLegacyJqLiteXHTMLReplacement

  • UNSAFE_restoreLegacyJqLiteXHTMLReplacement(): void
  • Restores the pre-1.8 behavior of jqLite that turns XHTML-like strings like <div /><span /> to <div></div><span></span> instead of <div><span></span></div>. The new behavior is a security fix so if you use this method, please try to adjust to the change & remove the call as soon as possible. Note that this only patches jqLite. If you use jQuery 3.5.0 or newer, please read jQuery 3.5 upgrade guide for more details about the workarounds.

    Returns void

bind

  • bind(context: any, fn: Function, ...args: any[]): Function
  • Parameters

    • context: any
    • fn: Function
    • Rest ...args: any[]

    Returns Function

bootstrap

  • Use this function to manually start up angular application.

    Parameters

    • element: string | Element | JQuery | Document

      DOM element which is the root of angular application.

    • Optional modules: (string | Function | any[])[]

      An array of modules to load into the application. Each item in the array should be the name of a predefined module or a (DI annotated) function that will be invoked by the injector as a config block.

    • Optional config: IAngularBootstrapConfig

      an object for defining configuration options for the application. The following keys are supported: - strictDi: disable automatic function annotation for the application. This is meant to assist in finding bugs which break minified code.

    Returns IInjectorService

copy

  • copy<T>(source: T, destination?: T): T
  • Creates a deep copy of source, which should be an object or an array.

    • If no destination is supplied, a copy of the object or array is created.
    • If a destination is provided, all of its elements (for array) or properties (for objects) are deleted and then all elements/properties from the source are copied to it.
    • If source is not an object or array (inc. null and undefined), source is returned.
    • If source is identical to 'destination' an exception will be thrown.

    Type parameters

    • T

    Parameters

    • source: T

      The source that will be used to make a copy. Can be any type, including primitives, null, and undefined.

    • Optional destination: T

      Destination into which the source is copied. If provided, must be of the same type as source.

    Returns T

equals

  • equals(value1: any, value2: any): boolean
  • Parameters

    • value1: any
    • value2: any

    Returns boolean

errorHandlingConfig

  • Configure several aspects of error handling in AngularJS if used as a setter or return the current configuration if used as a getter

    Returns IErrorHandlingConfig

  • Parameters

    Returns void

extend

  • extend(destination: any, ...sources: any[]): any
  • Parameters

    • destination: any
    • Rest ...sources: any[]

    Returns any

forEach

  • forEach<T, U>(obj: U, iterator: (value: U[number], key: number, obj: U) => void, context?: any): U
  • forEach<T>(obj: {}, iterator: (value: T, key: string, obj: {}) => void, context?: any): {}
  • forEach(obj: any, iterator: (value: any, key: any, obj: any) => void, context?: any): any
  • Invokes the iterator function once for each item in obj collection, which can be either an object or an array. The iterator function is invoked with iterator(value, key), where value is the value of an object property or an array element and key is the object property key or array element index. Specifying a context for the function is optional.

    It is worth noting that .forEach does not iterate over inherited properties because it filters using the hasOwnProperty method.

    Type parameters

    • T

    • U: ArrayLike<T, U> = T[]

    Parameters

    • obj: U

      Object to iterate over.

    • iterator: (value: U[number], key: number, obj: U) => void

      Iterator function.

        • (value: U[number], key: number, obj: U): void
        • Parameters

          • value: U[number]
          • key: number
          • obj: U

          Returns void

    • Optional context: any

      Object to become context (this) for the iterator function.

    Returns U

  • Invokes the iterator function once for each item in obj collection, which can be either an object or an array. The iterator function is invoked with iterator(value, key), where value is the value of an object property or an array element and key is the object property key or array element index. Specifying a context for the function is optional.

    It is worth noting that .forEach does not iterate over inherited properties because it filters using the hasOwnProperty method.

    Type parameters

    • T

    Parameters

    • obj: {}

      Object to iterate over.

      • [index: string]: T
    • iterator: (value: T, key: string, obj: {}) => void

      Iterator function.

        • (value: T, key: string, obj: {}): void
        • Parameters

          • value: T
          • key: string
          • obj: {}
            • [index: string]: T

          Returns void

    • Optional context: any

      Object to become context (this) for the iterator function.

    Returns {}

    • [index: string]: T
  • Invokes the iterator function once for each item in obj collection, which can be either an object or an array. The iterator function is invoked with iterator(value, key), where value is the value of an object property or an array element and key is the object property key or array element index. Specifying a context for the function is optional.

    It is worth noting that .forEach does not iterate over inherited properties because it filters using the hasOwnProperty method.

    Parameters

    • obj: any

      Object to iterate over.

    • iterator: (value: any, key: any, obj: any) => void

      Iterator function.

        • (value: any, key: any, obj: any): void
        • Parameters

          • value: any
          • key: any
          • obj: any

          Returns void

    • Optional context: any

      Object to become context (this) for the iterator function.

    Returns any

fromJson

  • fromJson(json: string): any
  • Parameters

    • json: string

    Returns any

identity

  • identity<T>(arg?: T): T
  • Type parameters

    • T

    Parameters

    • Optional arg: T

    Returns T

injector

  • Parameters

    • Optional modules: any[]
    • Optional strictDi: boolean

    Returns IInjectorService

isArray

  • isArray(value: any): value is any[]
  • Parameters

    • value: any

    Returns value is any[]

isDate

  • isDate(value: any): value is Date
  • Parameters

    • value: any

    Returns value is Date

isDefined

  • isDefined(value: any): boolean
  • Parameters

    • value: any

    Returns boolean

isElement

  • isElement(value: any): boolean
  • Parameters

    • value: any

    Returns boolean

isFunction

  • isFunction(value: any): value is Function
  • Parameters

    • value: any

    Returns value is Function

isNumber

  • isNumber(value: any): value is number
  • Parameters

    • value: any

    Returns value is number

isObject

  • isObject(value: any): value is Object
  • isObject<T>(value: any): value is T
  • Parameters

    • value: any

    Returns value is Object

  • Type parameters

    • T

    Parameters

    • value: any

    Returns value is T

isString

  • isString(value: any): value is string
  • Parameters

    • value: any

    Returns value is string

isUndefined

  • isUndefined(value: any): boolean
  • Parameters

    • value: any

    Returns boolean

merge

  • merge(dst: any, ...src: any[]): any
  • Deeply extends the destination object dst by copying own enumerable properties from the src object(s) to dst. You can specify multiple src objects. If you want to preserve original objects, you can do so by passing an empty object as the target: var object = angular.merge({}, object1, object2).

    Unlike extend(), merge() recursively descends into object properties of source objects, performing a deep copy.

    Parameters

    • dst: any

      Destination object.

    • Rest ...src: any[]

      Source object(s).

    Returns any

module

  • module(name: string, requires?: string[], configFn?: Injectable<Function>): IModule
  • The angular.module is a global place for creating, registering and retrieving Angular modules. All modules (angular core or 3rd party) that should be available to an application must be registered using this mechanism.

    When passed two or more arguments, a new module is created. If passed only one argument, an existing module (the name passed as the first argument to module) is retrieved.

    Parameters

    • name: string

      The name of the module to create or retrieve.

    • Optional requires: string[]

      The names of modules this module depends on. If specified then new module is being created. If unspecified then the module is being retrieved for further configuration.

    • Optional configFn: Injectable<Function>

      Optional configuration function for the module.

    Returns IModule

noop

  • noop(...args: any[]): void
  • Parameters

    • Rest ...args: any[]

    Returns void

reloadWithDebugInfo

  • reloadWithDebugInfo(): void
  • Returns void

Optional resumeBootstrap

  • If window.name contains prefix NG_DEFER_BOOTSTRAP! when angular.bootstrap is called, the bootstrap process will be paused until angular.resumeBootstrap() is called.

    Parameters

    • Optional extraModules: string[]

      An optional array of modules that should be added to the original list of modules that the app was about to be bootstrapped with.

    Returns IInjectorService

toJson

  • toJson(obj: any, pretty?: number | boolean): string
  • Parameters

    • obj: any
    • Optional pretty: number | boolean

    Returns string

Generated using TypeDoc