nativescript-oauth2
Advanced tools
Comparing version 3.0.6 to 3.0.7
@@ -10,7 +10,10 @@ import * as applicationModule from '@nativescript/core/application'; | ||
if (applicationModule.ios.delegate === undefined) { | ||
let UIApplicationDelegateImpl = class UIApplicationDelegateImpl extends UIResponder { | ||
}; | ||
UIApplicationDelegateImpl = __decorate([ | ||
ObjCClass(UIApplicationDelegate) | ||
], UIApplicationDelegateImpl); | ||
var UIApplicationDelegateImpl = /** @class */ (function (_super) { | ||
__extends(UIApplicationDelegateImpl, _super); | ||
function UIApplicationDelegateImpl() { | ||
return _super !== null && _super.apply(this, arguments) || this; | ||
} | ||
UIApplicationDelegateImpl.ObjCProtocols = [UIApplicationDelegate]; | ||
return UIApplicationDelegateImpl; | ||
}(UIResponder)); | ||
applicationModule.ios.delegate = UIApplicationDelegateImpl; | ||
@@ -17,0 +20,0 @@ } |
{ | ||
"name": "nativescript-oauth2", | ||
"version": "3.0.6", | ||
"version": "3.0.7", | ||
"description": "OAuth 2 generic authorization plugin for NativeScript that doesn't install third party native libraries", | ||
@@ -5,0 +5,0 @@ "main": "oauth", |
@@ -43,8 +43,4 @@ # OAuth 2 Plugin for NativeScript | ||
Register your mobile app [here](https://apps.dev.microsoft.com). This will require you to login with your Office 365 account. You can then click the big "Add an app" button and go through the steps listed there, starting with giving you app a name. On the app creation screen, you need to do 3 things: | ||
Register your mobile app [here](https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationsListBlade). | ||
1. Click the "Add Platform" button and select "Mobile application" | ||
2. Copy the "Client Id" GUID from the Mobile Application section. | ||
3. Click "Save" at the bottom. | ||
Microsoft login will work either with the in-app webview method, in which case your redirectUri config property can be set to `urn:ietf:wg:oauth:2.0:oob`. Or it can use the more secure method that doesn't require a client secret, but it will need to have a custom URL scheme registered (see below). | ||
@@ -51,0 +47,0 @@ |
@@ -32,4 +32,7 @@ import * as querystring from "querystring"; | ||
}; | ||
const options = this.client.provider.options; | ||
const body = querystring.stringify({ | ||
client_id: options.clientId, | ||
token: this.client.tokenResult.refreshToken, | ||
token_type_hint: "refresh_token" | ||
}); | ||
@@ -36,0 +39,0 @@ Http.request({ |
81535
27
1442
395