You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Quickstart: Sign in users and acquire an access token from a JavaScript single-page application
26
26
27
-
In this quickstart, you learn how to use a code sample that demonstrates how a JavaScript single-page application (SPA) can sign in users of personal accounts, work accounts, and school accounts. A JavaScript SPA can also get an access token to call the Microsoft Graph API or any web API.
28
-
29
-

27
+
In this quickstart, you use a code sample to learn how a JavaScript single-page application (SPA) can sign in users of personal accounts, work accounts, and school accounts. A JavaScript SPA can also get an access token to call the Microsoft Graph API or any web API. (See [How the sample works](#how-the-sample-works) for an illustration.)
30
28
31
29
## Prerequisites
32
30
33
-
This quickstart requires the following setup:
34
-
* To run the project with a Node.js server, download and install [Node.js](https://nodejs.org/en/download/).
35
-
* To edit the project files, download and install [Visual Studio Code](https://code.visualstudio.com/download).
36
-
* To run the project as a Visual Studio solution, download and install [Visual Studio 2019](https://visualstudio.microsoft.com/downloads/).
31
+
* Azure subscription - [create one for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F)
32
+
*[Node.js](https://nodejs.org/en/download/).
33
+
* Either [Visual Studio Code](https://code.visualstudio.com/download) (to edit project files), or [Visual Studio 2019](https://visualstudio.microsoft.com/downloads/) (ro run the project as a Visual Studio Solution).
37
34
38
35
> [!div renderon="docs"]
39
36
> ## Register and download your quickstart application
@@ -81,8 +78,6 @@ Select the option that's suitable to your development environment:
81
78
82
79
* (Optional) To run the project with the IIS server, [download the Visual Studio project](https://github.com/Azure-Samples/active-directory-javascript-graphapi-v2/archive/vsquickstart.zip). Extract the zip file to a local folder (for example, *C:\Azure-Samples*).
83
80
84
-
85
-
86
81
#### Step 3: Configure your JavaScript app
87
82
88
83
> [!div renderon="docs"]
@@ -144,6 +139,10 @@ After the browser loads the application, select **Sign In**. The first time that
144
139
145
140
## More information
146
141
142
+
### How the sample works
143
+
144
+

145
+
147
146
### msal.js
148
147
149
148
The MSAL library signs in users and requests the tokens that are used to access an API that's protected by Microsoft identity platform. The quickstart *index.html* file contains a reference to the library:
0 commit comments