Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@leapllc/parse

parse-community15BSD-3-Clause2.11.1

The Parse JavaScript SDK

cloud, mobile, api

readme

Parse Platform

Parse SDK for JavaScript

A library that gives you access to the powerful Parse Server backend from your JavaScript app.

Follow on Twitter Join the conversation License Build status Backers on Open Collective Sponsors on Open Collective

Test coverage npm version CDNJS version Greenkeeper badge


For more information on Parse and its features, see the website, the JavaScript guide, the Cloud Code guide or API Reference.

Getting Started

The easiest way to integrate the Parse SDK into your JavaScript project is through the npm module. However, if you want to use a pre-compiled file, you can fetch it from unpkg. The development version is available at https://unpkg.com/parse/dist/parse.js, and the minified production version is at https://unpkg.com/parse/dist/parse.min.js.

Using Parse on Different Platforms

The JavaScript ecosystem is wide and incorporates a large number of platforms and execution environments. To handle this, the Parse npm module contains special versions of the SDK tailored to use in Node.js and React Native environments. Not all features make sense in all environments, so using the appropriate package will ensure that items like local storage, user sessions, and HTTP requests use appropriate dependencies. For server side rendered applications, you may set the SERVER_RENDERING variable to prevent warnings at runtime.

To use the npm modules for a browser based application, include it as you normally would:

const Parse = require('parse');

For server-side applications or Node.js command line tools, include 'parse/node':

// In a node.js environment
const Parse = require('parse/node');

For React Native applications, include 'parse/react-native':

// In a React Native application
const Parse = require('parse/react-native');

// On React Native >= 0.50 and Parse >= 1.11.0, set the Async
const AsyncStorage = require('react-native').AsyncStorage;
Parse.setAsyncStorage(AsyncStorage);

For WeChat miniprogram, include 'parse/weapp':

// In a WeChat miniprogram
const Parse = require('parse/weapp');

If you want to use a pre-compiled file, you can fetch it from unpkg. The development version is available at https://unpkg.com/parse/dist/parse.weapp.js, and the minified production version is at https://unpkg.com/parse/dist/parse.weapp.min.js.

For TypeScript applications, install '@types/parse':

$ npm install @types/parse

Types are updated manually after every release. If a definition doesn't exist, please submit a pull request to @types/parse

Upgrading to Parse SDK 2.0.0

With Parse SDK 2.0.0, gone are the backbone style callbacks and Parse.Promises.

We have curated a migration guide that should help you migrate your code.

3rd Party Authentications

Parse Server supports many 3rd Party Authenications. It is possible to linkWith any 3rd Party Authentication by creating a custom authentication module.

Want to ride the bleeding edge?

We recommend using the most recent tagged build published to npm for production. However, you can test not-yet-released versions of the Parse-SDK-JS by referencing specific branches in your package.json. For example, to use the master branch:

npm install parse-community/Parse-SDK-JS.git#master

Experimenting

You can also use your own forks, and work in progress branches by specifying them:

npm install github:myUsername/Parse-SDK-JS#my-awesome-feature

And don't forget, if you plan to deploy it remotely, you should run npm install with the --save option.

Contributing

We really want Parse to be yours, to see it grow and thrive in the open source community. Please see the Contributing to Parse Javascript SDK guide.

License

Copyright (c) 2015-present, Parse, LLC.
All rights reserved.

This source code is licensed under the BSD-style license found in the
LICENSE file in the root directory of this source tree. An additional grant
of patent rights can be found in the PATENTS file in the same directory.

As of April 5, 2017, Parse, LLC has transferred this code to the parse-community organization, and will no longer be contributing to or distributing this code.

changelog

Parse-SDK-JS

master

Full Changelog

2.11.0

Full Changelog

New Features

  • Support encrypting current user (#1036)
  • File Upload Progress on Wechat (#1029)

Improvements

  • Support query.cancel() on Node (#1030)

Fixes

  • File Upload Progress on browser (#1029)
  • User signup with installationId (#1031)

2.10.0

Full Changelog

New Features

  • Add query.fromNetwork() (#1002)
  • Add query.cancel() (browser only) (#1003)
  • Support custom request headers (#1019)

Fixes

  • To subclass Parse.User: Parse.Object.registerSubclass('_User', CustomUser);

Security Address Security Advisory of possible leak of sensitive user info. (#d110617), big thanks to Colin Ulin for identifying the problem, following the vulnerability disclosure guidelines

2.9.1

Full Changelog

Fixes

2.9.0

Full Changelog

Deprecation _linkWith and _logInWith are deprecated. Replace with linkWith and logInWith respectively. (#963)

New Features

  • Set Class Level Permission via Parse.Schema (#960)
  • Set required fields and default values via Parse.Schema (#961)
  • Add installationId to LiveQuery (#977)
  • Add response object to LiveQuery (#979)
  • Support query.map, query.filter, query.reduce (#987)

Fixes

  • Can unlink without provider in cloud code (#971)
  • Properly store User Subclass in Storage (#978)

Improvements

  • User subclass support for logInWith, hydrate, me, current (#968)
  • Remove unused options from Parse.Schema (#959)
  • Documentation for linking users and custom auth (#963)
  • Generate installationId as uuid v4 (#972)
  • Reuse StorageController for LDS (#984)

2.8.0

Full Changelog

New Features

  • Parse.File save cancel (#948)
  • Parse.File getData cancel (#951)

Fixes

  • React Native Emitter module (#946)
  • Parse.Schema deleteIndex, deleteField returns Parse.Schema (#949)

Improvements

  • Compiling on Windows (#947)
  • Generate _localId as UUID (#956)

2.7.1

Full Changelog

New Features

  • Support for ParseConfig.save with masterKeyOnlyFlags option (#910) (Requires Parse-Server 3.8.0+)
  • Support for ParseConfig.get with useMasterKey option (#907)

2.7.0

Full Changelog

New Features

  • Support for ParseObject.fetchAllIfNeededWithInclude (#900)
  • Support for ParseObject.exists (#898)
  • Support for ParseObject.save with cascadeSave option (#881)

Fixes

  • ParseUser.become should return subclass (#897)
  • Ensure LiveQuery subscribes before returning subscription (#878)

Improvements

  • Remove deprecated @babel/polyfill (#877)

2.6.0

Full Changelog

New Features:

  • Support configurable WebSocketController (#64f359a)
  • Support for Wechat Mini Program (#874)
  • Support withCount query constraint (#868)

Improvements:

  • Fix SERVER_RENDERING environment variable (#873)

2.5.1

Full Changelog

  • FIX: NPM credentials

2.5.0

Full Changelog

New Features:

  • Support query exclude keys (#857)
  • Support query read preference (#855)
  • Support object isDataAvailable (#856)

Improvements:

  • Add options for AnonymousUtils (#860)
  • Stateless UserController (#846)
  • Fix Facebook login isExisted (#845)
  • Allow any Blob to be uploaded (#837)
  • Support _linkWith if no provider (#810)
  • LDS: Improve querying dates (#808)
  • Support testing on Windows (#808)
  • Support installing SDK from branch (#821)

2.4.0

Full Changelog

New Features:

  • LocalDatastore: Support Users (#801)
  • LiveQuery subscribe with sessionToken (#791)

Improvements:

  • LocalDatastore: Improve pinning unsaved objects (#795)
  • LocalDatastore: Improve error handling (#803)

2.3.2

Full Changelog

  • Support getData from Parse.File (#780)
  • Parse.FacebookUtils logIn and link support MasterKey and SessionToken options (#779)
  • Remove node modules http and https from React-Native build (#776)

2.3.1

Full Changelog

  • _linkWith and _unlinkFrom support MasterKey and SessionToken options (#767)
  • Correct homepage in package.json (#9e198b3)
  • Add Issues template for opening GitHub Issue (#760)
  • Add Public email address to satisfy an npmjs requirement (#764)
  • File uri upload for Browser / React-Native (#765)

2.3.0

Full Changelog

  • LocalDatastore fixes for React-Native (#753)
  • LocalDatastore update from Server (#734)
  • Support for Anonymous Users (#750)
  • File upload via uri (#749)
  • Add support to secured endpoints throught Authorization header (#358)
  • Remove authResponse in FacebookUtils (#728)
  • UserSubclass.logIn and UserSubclass.signUp returns subclass (#756)
  • Subscribe to multiple LiveQuery subscriptions (#758)

2.2.1

Full Changelog

  • Addresses issue with babel runtime regenerator (#740)

2.2.0

Full Changelog

  • Support for Local Datastore (#612)
  • LiveQuery override data on update (#718) (Requires Parse-Server 3.1.3+)
  • Support setting user from JSON (hydrate) (#730)
  • Improve dot notation for updating nested objects (#729)
  • LiveQuery handle unset operation (#714) (Requires Parse-Server 3.1.3+)
  • Add original object to LiveQuery events (#712) (Requires Parse-Server 3.1.3+)
  • Add support for providing file upload progress. (#373) (Browser Only)
  • Support clone with relation (#382)
  • Add batchSize to saveAll / destroyAll (#701)
  • Add save Method for Parse.Config (#684)
  • Allow specific keys to be reverted in unsaved objects (#565)
  • Handle undefined in Cloud Code (#682)
  • Validate if geopoint values is number (#671)
  • LiveQuery Support for Subclasses (#662)

2.1.0

Full Changelog

  • Parse.Error now inherits from Error (#658)

2.0.2

Full Changelog

  • Fixes issue affecting unsubscribing from liveQueries (#640)
  • Adds support for aggregate stages with identical names (#637)
  • Adds ability to fetch an object with includes (#631)
  • Adds support for $nor operator in queries (#634)
  • Adds support for containedBy operator in queries (#633)
  • Adds support for includeAll (#632)

2.0.1

  • Ensure we only read the job status id header if present. (#623)

2.0.0

  • Parse.Promise has been replaced by native Promises (#620)
  • Backbone style callbacks are removed (#620)