kinvey-js-sdk
Advanced tools
Comparing version 3.13.0-next.39 to 4.0.0
@@ -6,3 +6,15 @@ Object.defineProperty(exports, "__esModule", { value: true }); | ||
var kinvey_1 = require("./kinvey"); | ||
var kinvey_2 = require("./errors/kinvey"); | ||
function init(config) { | ||
// Check that an appKey was provided | ||
if (config.kinveyConfig.appKey === null && config.kinveyConfig.appKey === undefined) { | ||
throw new kinvey_2.KinveyError('No app key was provided to initialize the Kinvey JavaScript SDK.'); | ||
} | ||
// Check that an appSecret or masterSecret was provided | ||
if (config.kinveyConfig.appSecret === null | ||
&& config.kinveyConfig.appSecret === undefined | ||
&& config.kinveyConfig.masterSecret === null | ||
&& config.kinveyConfig.masterSecret === undefined) { | ||
throw new kinvey_2.KinveyError('No app secret was provided to initialize the Kinvey JavaScript SDK.'); | ||
} | ||
config_1.setConfig(config_1.ConfigKey.KinveyConfig, config.kinveyConfig); | ||
@@ -9,0 +21,0 @@ config_1.setConfig(config_1.ConfigKey.HttpAdapter, config.httpAdapter); |
@@ -20,3 +20,3 @@ import { Query } from '../query'; | ||
static loginWithRedirectUri(redirectUri: string, options?: MICOptions): Promise<KinveyUser>; | ||
static loginWithUsernamePassword(username: string, password: string, options?: MICOptions): Promise<KinveyUser>; | ||
static loginWithMICUsingResourceOwnerCredentials(username: string, password: string, options?: MICOptions): Promise<KinveyUser>; | ||
static loginWithMIC(redirectUri: string, authorizationGrant: AuthorizationGrant, options?: any): Promise<KinveyUser>; | ||
@@ -23,0 +23,0 @@ static logout(options?: any): Promise<KinveyUser>; |
@@ -7,3 +7,3 @@ Object.defineProperty(exports, "__esModule", { value: true }); | ||
var loginWithRedirectUri_1 = require("./loginWithRedirectUri"); | ||
var loginWithUsernamePassword_1 = require("./loginWithUsernamePassword"); | ||
var loginWithMICUsingResourceOwnerCredentials_1 = require("./loginWithMICUsingResourceOwnerCredentials"); | ||
var loginWithMIC_1 = require("./loginWithMIC"); | ||
@@ -42,4 +42,4 @@ exports.AuthorizationGrant = loginWithMIC_1.AuthorizationGrant; | ||
}; | ||
User.loginWithUsernamePassword = function (username, password, options) { | ||
return loginWithUsernamePassword_1.loginWithUsernamePassword(username, password, options); | ||
User.loginWithMICUsingResourceOwnerCredentials = function (username, password, options) { | ||
return loginWithMICUsingResourceOwnerCredentials_1.loginWithMICUsingResourceOwnerCredentials(username, password, options); | ||
}; | ||
@@ -46,0 +46,0 @@ User.loginWithMIC = function (redirectUri, authorizationGrant, options) { |
{ | ||
"name": "kinvey-js-sdk", | ||
"description": "Kinvey JavaScript SDK for JavaScript applications.", | ||
"version": "3.13.0-next.39", | ||
"version": "4.0.0", | ||
"license": "Apache-2.0", | ||
@@ -6,0 +6,0 @@ "homepage": "https://github.com/Kinvey/js-sdk/tree/master/packages/js-sdk", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
510078
7642
0