npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@amag-ch/sap_cap_common_launchpad

v1.7.1

Published

Lauchpad Sandbox for local testing

Downloads

117

Readme

npm version npm downloads

Lauchpad Sandbox for local testing

Table of Contents

Installing

Using npm:

$ npm install @amag-ch/sap_cap_common_launchpad --save-dev

Using yarn:

$ yarn add @amag-ch/sap_cap_common_launchpad --dev

Usage

Before cds version 6.8.0, add following to your custom server.js:

if (process.env.NODE_ENV !== 'production') {
    cds.once('bootstrap', () => new (require('@amag-ch/sap_cap_common_launchpad'))())
}

or the long version

if (process.env.NODE_ENV !== 'production') {
    const Lauchpad = require('@amag-ch/sap_cap_common_launchpad')
    cds.once('bootstrap', () => new Lauchpad())
}

Since cds version 6.8.0 the cds plugin feature register the launchpad automatically

Afterthen the launchpad is available under http://localhost:4004/$launchpad

Applications which should be displayed must be defined in package.json of your project under sapux

{
    "sapux": [
        "app/application1",
        "app/application2"
    ]
}

Configuration

Configuration by programming

Call new Lauchpad({...}) constructor to change the default options

{
    path: '/$launchpad', // Path under which the launchpad serves
    name: 'Launchpad', // Name of the lauchpad
    title: 'Lauchpad Sandbox', // Title of the launchpad
    cdn: 'https://ui5.sap.com', // URL from where the libs should be loaded
    version: '', // Specific UI5 version
    libs: 'sap.ui.core, sap.m, sap.ushell, sap.fe.templates', // UI5 libraries should be loaded at startup
    theme: 'sap_horizon' // UI5 theme
}

Configuration by definition

Add launchpad configuration in package.json or .cdsrc.json

{
    "cds": {
        "launchpad": {
            "version": "1.115.1",
            "theme": "sap_horizon_dark"
        }
    }
}

Own groups

If the project have multipe tiles, it's possible to move them in own groups

{
    "cds": {
        "launchpad": {
            "groups": {
                "business": [
                    "app/application1"
                ],
                "technical": [
                    "app/application2"
                ]
            }
        }
    }
}

Group titles

If auto generated groups titles doesn't fit, then those can be set manually

{
    "cds": {
        "launchpad": {
            "titles": {
                "groups": {
                    "business" "Different title for business"
                }
            },
            "groups": {
                "business": [
                    "app/application1"
                ],
                "technical": [
                    "app/application2"
                ]
            }
        }
    }
}

Own catalogs

If the project have multipe tiles, it's possible to move them in own catalogs

{
    "cds": {
        "launchpad": {
            "catalogs": {
                "technical": [
                    "app/application2"
                ]
            }
        }
    }
}

Catalog titles

If auto generated catalogs titles doesn't fit, then those can be set manually

{
    "cds": {
        "launchpad": {
            "titles": {
                "catalogs": {
                    "technical" "Different title for technical"
                }
            },
            "catalogs": {
                "technical": [
                    "app/application2"
                ]
            }
        }
    }
}

Roles

If tiles / applications should be only add, if logined user have the corresponding rights, then roles and assignment must be defined.

If an application is not assigned to a role, then it's general accessable.

It's only working if cds.middlewares are active.

{
    "cds": {
        "launchpad": {
            "titles": {
                "groups": {
                    "business" "Different title for business"
                }
            },
            "roles": {
                "BusinessUser": [
                    "app/application1"
                ],
                "TechnicalUser": [
                    "app/application2"
                ]
            },
            "groups": {
                "business": [
                    "app/application1"
                ],
                "technical": [
                    "app/application2"
                ]
            }
        }
    }
}

Target only applications

If applications should be started only over target navigation, then those can be added to special hidden catalog and group.

{
    "cds": {
        "launchpad": {
            "catalogs": {
                "business": [
                    "app/application1"
                ],
                "hidden": [
                    "app/application2"
                ]
            },            
            "groups": {
                "business": [
                    "app/application1"
                ],
                "hidden": [
                    "app/application2"
                ]
            }
        }
    }
}

License

MIT