Skip to Content
avatar image
Former Member

Why does these two statements differ in Angular js and SAP Ui5

Hello Everybody

I am trying to learn SAP Ui5 by comparing it with angular js

So in a simple Hello World Program

I find that the Angular just is using a statement

<html ng-app='helloapp'>

As per my understanding this is done to tell the computer that this is the root node of the html page .

But in SAP UI5 we are using the statement

<html lang="en">

This statement feels like it more dealing with the language rather than defining the root node of the page .

Could someone explain me the anomaly, since this is the first time I am diving into web development .

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Feb 26 at 11:10 AM

    ng-app is a tag specific to Angular. lang is a HTML5 tag to express the document language.

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 27 at 07:33 AM

    Hi Bodhisattwa,

    <html ng-app='helloapp'>

    AngularJS extends HTML with ng-directives in which the ng-app directive defines an AngularJS application.

    <html lang="en">

    The HTML lang attribute can be used to declare the language of a Web page or a portion of a Web page. This is meant to assist search engines and browsers

    Thanks,

    Parul

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 27 at 08:13 AM

    I feel you are going wrong by learning one language using another. Its a classic mistake anyone does when learning any language.

    In my German class, the first instruction of my trainer was "Please don't learn German through English". I would propose the same to you. Please don't learn AngularJS using SAPUI5.

    Regards,

    Sharath

    Add comment
    10|10000 characters needed characters exceeded