• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

parse-community/Parse-SDK-JS: The JavaScript SDK for Parse Platform

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称:

parse-community/Parse-SDK-JS

开源软件地址:

https://github.com/parse-community/Parse-SDK-JS

开源编程语言:

JavaScript 99.9%

开源软件介绍:

parse-repository-header-sdk-js


Build Status CI alpha Build Status CI release Snyk Badge Coverage

Node Version auto-release

npm latest version npm beta version npm alpha version

Backers on Open Collective Sponsors on Open Collective License Forum Twitter


A library that gives you access to the powerful Parse Server backend from your JavaScript app. 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');
// ES6 Minimized
import Parse from 'parse/dist/parse.min.js';

For web worker or browser applications, indexedDB storage is available:

Parse.CoreManager.setStorageController(Parse.IndexedDB);

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.js':

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

// 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.

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.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
audiocogs/aurora.js: JavaScript audio decoding framework发布时间:2022-07-07
下一篇:
keshavsingh4522/javascript发布时间:2022-07-07
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap