Coder Social home page Coder Social logo

santhoshbomma9 / active-directory-javascript-singlepageapp-angular Goto Github PK

View Code? Open in Web Editor NEW

This project forked from azure-samples/active-directory-javascript-singlepageapp-angular

0.0 1.0 0.0 160 KB

A simple Angular single page application calling the Microsoft Graph using MSAL Angular (Azure AD V2 endpoint)

License: MIT License

JavaScript 11.37% TypeScript 79.25% CSS 1.30% HTML 8.08%

active-directory-javascript-singlepageapp-angular's Introduction

page_type languages products description urlFragment
sample
javascript
nodejs
azure-active-directory
A simple Angular single page application calling the Microsoft Graph using MSAL Angular (Azure AD V2 endpoint).
active-directory-javascript-singlepageapp-angular

MSAL Angular Sample Application

A simple Angular single-page application which demonstrates how to configure MSAL Angular to login, logout, protect a route, and acquire an access token for a protected resource such as the Microsoft Graph.

Note: This sample's structure was generated with the Angular CLI.

Contents

File/folder Description
e2e End-to-end test files.
src Sample source code.
.editorconfig Defines editor config settings.
.gitignore Define what to ignore at commit time.
angular.json Angular configuration file.
browserslist BrowsersList configuration file.
CHANGELOG.md List of changes to the sample.
CODE_OF_CONDUCT.md Code of Conduct information.
CONTRIBUTING.md Guidelines for contributing to the sample.
karma.conf.js Configuration for the karma test runner.
LICENSE The license for the sample.
NG_README.md README auto-generated by the Angular CLI.
package-lock.json Lockfile for npm.
package.json Package manifest for npm.
README.md This README file.
SECURITY.md Security disclosures.
tsconfig.*.json TypeScript configuration files.
tslint.json TS Lint configuration files.

Prerequisites

Node must be installed to run this sample.

Setup

  1. Register a new application in the Azure Portal. Ensure that the application is enabled for the implicit flow.
  2. Open the src/app/app.module.ts file and provide the required configuration values (inside MsalModule.forRoot).
  3. On the command line, navigate to the root of the repository, and run npm install to install the project dependencies via npm.

Running the sample

  1. To start the sample application, run npm start.
  2. Next, open a browser to http://localhost:4200.

Key concepts

This sample demonstrates the following MSAL Angular concepts:

  • Configuration
  • Login
  • Logout
  • Protecting a route
  • Acquiring an access token and attaching it to http calls

Contributing

If you'd like to contribute to this sample, see CONTRIBUTING.MD.

Code of Conduct

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

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.