@eo-sdk/core
TypeScript icon, indicating that this package has built-in type declarations

11.10.0-beta.1 • Public • Published

@eo-sdk/core library

Use @eo-sdk/core library to create your own custom yuuvis® RAD client application.

Installation

npm install @eo-sdk/core --save

Usage

Import EoCoreModule in your applications root NgModule.

import {BrowserModule} from '@angular/platform-browser';
import {NgModule} from '@angular/core';
import {EoCoreModule} from '@eo-sdk/core';

@NgModule({
    imports: [
        BrowserModule,
        EoCoreModule.forRoot()
    ],
    bootstrap: [AppComponent]
})
export class AppModule { }

Apply configuration

By default EoCoreModule is set up with the following configuration

{
  "main": ['assets/_default/config/main.json', 'assets/_default/config/extend.json'],
  "translations": ['assets/_default/i18n/']
}

This tells the module where to find the main config file and where the translations of your application can be found.

If you want to change / override those values, you can provide the modules forRoot() function with your custom config.

@NgModule({
    imports: [
        BrowserModule,
        EoCoreModule.forRoot({
          main: ['assets/_default/config/main.json', 'assets/config/main.json'],
          translations: ['assets/_default/i18n/', 'assets/i18n/']
        })
    ],
    bootstrap: [AppComponent]
})
export class AppModule { }

Main configuration file

You need to provide a main configuration file for setting up the module.

{
 "uri": {
   "serviceBase": "/rest-ws/service",
   "searchBase": "/search",
   "contextBase": "/structure",
   "inboxBase": "/inboxservice",
   "bpmBase": "/bpm",
   "agentBase": "/agent",
   "statusBase": "/status"
 },
 "search": {
   "searchMode": "idxs",
   "trackTotalHits": false,
   "limit": 50
 },
 "languages": [
   {
     "iso": "de",
     "label": "Deutsch"
   },
   {
     "iso": "en",
     "label": "English",
     "fallback": true
   }
 ]
}

Using translations in other modules than the root module

If you structure your application by using several modules you may want to use translations inside of those modules as well. In order to do so, just import EoSharedModule in your feature module and you are able to use translate directives and services there.

@NgModule({
    imports: [
        EoSharedModule
    ]
})
export class MyFeatureModule { }

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i @eo-sdk/core

Weekly Downloads

131

Version

11.10.0-beta.1

License

MIT

Unpacked Size

1.84 MB

Total Files

240

Last publish

Collaborators

  • eo-sdk-npm
  • optimal-systems-npm