@iapps/ng-dhis2-shell
TypeScript icon, indicating that this package has built-in type declarations

1.0.4 • Public • Published

ng-dhis2-shell

ng-dhis2-shell is an angular based library that provide a DHIS2 shell (DHIS2 Header bar, loading, login model etc) on angular application when building DHIS2 based applications. The library wraps @dhis2/app-shell which is based on react library.

Installation

To add ng-dhis2-shell , run

ng add @iapps/ng-dhis2-shell

The ng add command will perform the following actions:

  • Add project dependencies to package.json
  • Add AppShellModule imports in app.module.ts
  • Rewrite the app.component.ts file by adding wrapper to dhis2 shell component
  • Add manifest.webapp in the workspace, this is file is needed when building application for installation in DHIS2 instance (You will need to manually add reference of this file in angular.json unders assets to have this available during building of application. This will be done automatically in later versions)
  • Update tsconfig.json file to add relevant properties to allow running react code in angular

Development environment

For better development experience, add proxy-config.json file in your workspace

{
  "/api": {
    "target": "https://play.dhis2.org/40.2.0/",
    "secure": false,
    "auth": "admin:district",
    "changeOrigin": true
  },
  "/dhis-web-commons": {
    "target": "https://play.dhis2.org/40.2.0/",
    "secure": false,
    "auth": "admin:district",
    "changeOrigin": true
  },
  "/icons": {
    "target": "https://play.dhis2.org/40.2.0/",
    "secure": false,
    "auth": "admin:district",
    "changeOrigin": true
  }
}

/@iapps/ng-dhis2-shell/

    Package Sidebar

    Install

    npm i @iapps/ng-dhis2-shell

    Weekly Downloads

    2

    Version

    1.0.4

    License

    none

    Unpacked Size

    64.6 kB

    Total Files

    19

    Last publish

    Collaborators

    • goodwile44
    • interactive.apps
    • rajab.mkomwa
    • mukulu
    • vincentminde
    • mgowanojr
    • vmataba
    • josephatj
    • chingalo
    • barnabasmakonda
    • waltervfaustine
    • ibrahimwickama
    • happinessnyanda
    • megamind97
    • baharajr
    • mdachi-codes