mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-3938] support for XMLHttpRequest.withCredentials flag (#4190)
* support XMLHttpRequest.withCredentials * proper defaults and json schema updates * remove outdated docs * remove empty declaration from app config * fix blob support
This commit is contained in:
committed by
Eugenio Romano
parent
08c9b6d117
commit
5887fa1052
@@ -66,22 +66,6 @@ Example of the default settings file content:
|
||||
Note that the settings in the example above are the default ones supplied with the server.
|
||||
You can override the values in your custom `app.config.json` file if necessary.
|
||||
|
||||
You can change the path or name of the configuration file when importing the [`CoreModule`](../../lib/core/core.module.ts) in your main application.
|
||||
|
||||
```ts
|
||||
...
|
||||
@NgModule({
|
||||
imports: [
|
||||
...
|
||||
CoreModule.forRoot({
|
||||
appConfigFile: 'app.production.config.json'
|
||||
})
|
||||
],
|
||||
...
|
||||
}
|
||||
export class AppModule { }
|
||||
```
|
||||
|
||||
Below is a simple example of using the [`AppConfigService`](../core/app-config.service.md) in practice.
|
||||
|
||||
**[app.component](../../demo-shell/src/app/app.component.ts).ts**
|
||||
@@ -156,3 +140,16 @@ of a property when the app config is loaded:
|
||||
console.log(logLevelValue); //this will be 'trace';
|
||||
});
|
||||
```
|
||||
|
||||
## XMLHttpRequest.withCredentials
|
||||
|
||||
In the configuration file, you can enable [XMLHttpRequest.withCredentials](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/withCredentials)
|
||||
for @alfresco/js-api calls and PDF Viewer.
|
||||
|
||||
```json
|
||||
{
|
||||
"auth": {
|
||||
"withCredentials": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
Reference in New Issue
Block a user