Git Product home page Git Product logo

dev-chester / generator-easy-ui5 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sap/generator-easy-ui5

1.0 1.0 0.0 290 KB

Generator for OpenUI5-based web-apps which use the official UI5 tooling and support deployment targets such as the SAP Cloud Platform

Home Page: https://blogs.sap.com/2019/02/05/introducing-the-easy-ui5-generator/

License: Apache License 2.0

JavaScript 88.38% CSS 0.09% HTML 11.53%

generator-easy-ui5's Introduction

Easy UI5 Generator

NPM version Build Status Dependency Status License Status

Description

Easy-ui5 is a Yeoman generator which enables you to create simple OpenUI5-based web-apps within seconds.

This generator has been created to simplify the creation of your OpenUI5 prototypes. Now you can scaffold simple UI5 projects from the shell/terminal of your choice. The current best practices (such as async) are already baked into our templates so you don't have to worry about the definition of the metadata files.

The purpose of this generator is to guide you on your first steps with SAPUI5 and SAP Cloud Platform deployments. Once you are familiar with those technologies, you might want to tweak the projects to adapt them for productive use-cases (such as continuous deployment pipelines and full i18n).

Target platforms

During the prompting phase, the generator will ask on which target platform your app should run. Currently, the following options are available:

Static webserver

This is the most basic option. Choose this option if you want to deploy the web app in your custom environment or host it on an arbitrary server.

Application Router @ Cloud Foundry

This is the most basic way to deploy the web app in Cloud Foundry-based environments. Besides the basic UI5 project, the generator will add an Approuter node.js-module that serves the web app.

Application Router @ SAP HANA XS Advanced

This is the standard way to deploy the web app in SAP HANA XSA-based environments. Besides the basic UI5 project, the generator will add an Approuter node.js-module that serves the web app.

Cloud Foundry HTML5 Application Repository

This option is a more sophisticate way to serve the web app from Cloud Foundry-based environments. The generator will include all modules that are included in the Application Router @ Cloud Foundry and, additionally, install a module to upload the web app to the HTML5 application repository during deploy-time. You can watch this presentation to learn more about the benefits of using the HTML5 application repository.

Fiori Launchpad on Cloud Foundry

Use this option if you would like to develop a Fiori Launchpad application that should run on Cloud Foundry. The generator will include all modules that are included in the Cloud Foundry HTML5 Application Repository and, additionally, install a module that adds Fiori Launchpad resources to the HTML5 application repository.

Installation

  1. Get Node.js (version 8.5 or higher)
  2. Install the generator
    npm install -g yo generator-easy-ui5
  3. Verify your installation to see if Yeoman has been installed correctly
    yo

Make sure you see the easy-ui5 generator listed.

Bootstrapping a new UI5 project

Create your first OpenUI5 App within a few seconds!

  1. Scaffold your OpenUI5 project
    yo easy-ui5
    
  2. Answer the prompts to create your OpenUI5 project
  3. Run it locally
    cd <your project name>
    npm start
    

Sub-generators to avoid recurring tasks

Add a new view

This sub-generator will create a new view (of the same type you specified during the creating of your project) and a new controller and route.

yo easy-ui5:newview

Create a custom control

Run the following command from your project's root to scaffold a custom control.

yo easy-ui5:newcontrol

Add a new model

This sub-generator will create a new model in your manifest. Currently, JSON and OData v2 models are supported with various configuration options.

yo easy-ui5:newmodel

Add a new component usage

This sub-generator will add a new component usage for component reuse to your manifest.

yo easy-ui5:newcomponentusage

Deployment

Depending on your target platform you'll need to install additional tools:

Cloud Foundry

Required tools

  1. Create a free SAP Cloud Platform Cloud account
  2. Install the Cloud Foundry Command Line Interface
    cf login
  3. Install the MultiApps CF CLI Plugin

Deploy

Call this command from the root directory to deploy the application to Cloud Foundry

npm run deploy

Optional: When using the HTML5 Applications Repository

Install the HTML5 Applications Repository CF CLI Plugin:

cf install-plugin -r CF-Community "html5-plugin"

With this tool you can update your web app without the need to deploy a new cloud application:

cf html5-push -n html5_repo_host .

SAP HANA XSA

Required tools

  1. SAP HANA or create a free SAP HANA Express system
  2. Install the XS CLI Client
    xs login

Deploy

Call this command from the root directory to deploy the application to HANA XSA

npm run deploy

Embedded Technologies

This project leverages (among others) the following Open Source projects:

Support

Please use the GitHub bug tracking system to post questions, bug reports or to create pull requests.

Contributing

We welcome any type of contribution (code contributions, pull requests, issues) to this easy-ui5 generator equally.

Please follow our instructions if you would like to contribute.

To-Do

The following aspects/features are not yet implemented:

  • Add SAP NetWeaver as a target platform
  • Decouple the sub-generators from the main flow. E.g. so that app router modules can be added after the generation of the UI5 web app.

Contributions are very much appreciated.

License

Copyright (c) 2020 SAP SE or an SAP affiliate company. All rights reserved. This project is licensed under the Apache Software License, Version 2.0 except as noted otherwise in the LICENSE file.

generator-easy-ui5's People

Contributors

uxkjaer avatar jonathanbaker7 avatar matz3 avatar dependabot[bot] avatar

Stargazers

Roman avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.