diff --git a/docs/en/UI/Angular/Content-Security-Strategy.md b/docs/en/UI/Angular/Content-Security-Strategy.md index 344aaf2a6e..c45cf23c58 100644 --- a/docs/en/UI/Angular/Content-Security-Strategy.md +++ b/docs/en/UI/Angular/Content-Security-Strategy.md @@ -8,12 +8,20 @@ ## API -### constructor(public nonce?: string) +### constructor + +```js +constructor(public nonce?: string) +``` - `nonce` enables whitelisting inline script or styles in order to avoid using `unsafe-inline` in [script-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src#Unsafe_inline_script) and [style-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src#Unsafe_inline_styles) directives. -### applyCSP(element: HTMLScriptElement | HTMLStyleElement): void +### applyCSP + +```js +applyCSP(element: HTMLScriptElement | HTMLStyleElement): void +``` This method maps the aforementioned properties to the given `element`. @@ -39,18 +47,28 @@ This method maps the aforementioned properties to the given `element`. Predefined content security strategies are accessible via `CONTENT_SECURITY_STRATEGY` constant. -### Loose(nonce: string) +### Loose + +```js +Loose(nonce: string) +``` `nonce` will be set. -### None() +### None + +```js +None() +``` Nothing will be done. -## What's Next? +## See Also + +- [DomInsertionService](./Dom-Insertion-Service.md) +- [ContentStrategy](./Content-Strategy.md) -TODO: Place new ContentStrategy link here. diff --git a/docs/en/UI/Angular/Cross-Origin-Strategy.md b/docs/en/UI/Angular/Cross-Origin-Strategy.md index 483fdfff59..ee188deebc 100644 --- a/docs/en/UI/Angular/Cross-Origin-Strategy.md +++ b/docs/en/UI/Angular/Cross-Origin-Strategy.md @@ -6,13 +6,24 @@ ## API -### constructor(public crossorigin: 'anonymous' | 'use-credentials', public integrity?: string) +### constructor + +```js +constructor( + public crossorigin: 'anonymous' | 'use-credentials', + public integrity?: string +) +``` - `crossorigin` is mapped to [the HTML attribute with the same name](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/crossorigin). - `integrity` is a hash for validating a remote resource. Its use is explained [here](https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity). -### setCrossOrigin(element: HTMLElement): void +### setCrossOrigin + +```js +setCrossOrigin(element: HTMLElement): void +``` This method maps the aforementioned properties to the given `element`. @@ -24,12 +35,20 @@ This method maps the aforementioned properties to the given `element`. Predefined cross-origin strategies are accessible via `CROSS_ORIGIN_STRATEGY` constant. -### Anonymous(integrity?: string) +### Anonymous + +```js +Anonymous(integrity?: string) +``` `crossorigin` will be set as `"anonymous"` and `integrity` is optional. -### UseCredentials(integrity?: string) +### UseCredentials + +```js +UseCredentials(integrity?: string) +``` `crossorigin` will be set as `"use-credentials"` and `integrity` is optional. diff --git a/docs/en/UI/Angular/Dom-Strategy.md b/docs/en/UI/Angular/Dom-Strategy.md index 1b5fb1011a..7d7e10c7f8 100644 --- a/docs/en/UI/Angular/Dom-Strategy.md +++ b/docs/en/UI/Angular/Dom-Strategy.md @@ -6,16 +6,26 @@ ## API -### constructor(public target?: HTMLElement, public position?: InsertPosition) +### constructor + +```js +constructor( + public target?: HTMLElement, + public position?: InsertPosition +) +``` - `target` is an HTMLElement (_default: document.head_). - `position` defines where the created element will be placed. All possible values of `position` can be found [here](https://developer.mozilla.org/en-US/docs/Web/API/Element/insertAdjacentElement) (_default: 'beforeend'_). -### insertElement(element: HTMLElement): void +### insertElement -This method inserts given `element` to `target` based on the `position`. +```js +insertElement(element: HTMLElement): void +``` +This method inserts given `element` to `target` based on the `position`. @@ -51,8 +61,7 @@ Predefined dom strategies are accessible via `DOM_STRATEGY` constant. -## What's Next? +## See Also +- [DomInsertionService](./Dom-Insertion-Service.md) - [LoadingStrategy](./Loading-Strategy.md) - -TODO: Place new InsertionStrategy link here. diff --git a/docs/en/UI/Angular/Lazy-Load-Service.md b/docs/en/UI/Angular/Lazy-Load-Service.md index f165075c8f..43ee7bc6b8 100644 --- a/docs/en/UI/Angular/Lazy-Load-Service.md +++ b/docs/en/UI/Angular/Lazy-Load-Service.md @@ -185,13 +185,21 @@ In this example, the second file needs the first one to be loaded beforehand. Rx -### loaded: Set +### loaded + +```js +loaded: Set +``` All previously loaded paths are available via this property. It is a simple [JavaScript Set](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set). -### load(strategy: LoadingStrategy, retryTimes?: number, retryDelay?: number): Observable +### load + +```js +load(strategy: LoadingStrategy, retryTimes?: number, retryDelay?: number): Observable +``` - `strategy` parameter is the primary focus here and is explained above. - `retryTimes` defines how many times the loading will be tried again before fail (_default: 2_). diff --git a/docs/en/UI/Angular/Loading-Strategy.md b/docs/en/UI/Angular/Loading-Strategy.md index 8fb7b68a45..1089875886 100644 --- a/docs/en/UI/Angular/Loading-Strategy.md +++ b/docs/en/UI/Angular/Loading-Strategy.md @@ -7,8 +7,15 @@ ## API +### constructor -### constructor(public path: string, protected domStrategy?: DomStrategy, protected crossOriginStrategy?: CrossOriginStrategy) +```js +constructor( + public path: string, + protected domStrategy?: DomStrategy, + protected crossOriginStrategy?: CrossOriginStrategy +) +``` - `path` is set to `