##CN 机器翻译请参照EN原版理解
angularfire是官方支持AngularJS结合火力点。火力点是一个 后端服务提供数据存储、验证、静态网站托管你的角的应用。
angularfire是核心客户的补充火力点。它为你提供了三角 服务:
firebaseobject美元同步对象firebasearray美元同步的集合firebaseauth美元认证、用户管理、路由
为了在你的项目中使用angularfire,你需要包括在您的HTML文件:
<!angularjs——>—— <脚本 SRC=“http:/ / / / / angularjs ajax.googleapis.com AJAX库/ / angular.min.js 1.5.0“></脚本><!firebase————> <脚本 SRC=<trans data-src="" "="" data-dst="“">“cdn.firebase.com https://////firebase.js 2.4.0客户端js<trans data-src="" "="" data-dst="“">“></脚本>
<!angularfire————> <脚本 SRC=<trans data-src="" "="" data-dst="“">“http:/ / / / / angularfire LIBS cdn.firebase.com / angularfire.min.js 1.2.0<trans data-src="" "="" data-dst="“">“></脚本>
使用上述URL下载的压缩和非压缩版本的angularfire从 Firebase CDN。你也可以从下载这个GitHub库发布的页面。火力点和角图书馆可以直接下载从各自的网站。
你也可以通过安装angularfire NPM和凉亭及其依赖项将自动下载 :
新安装angularfire --拯救美元
鲍尔安装angularfire --拯救美元
一旦你有angularfire及其依赖关系到你的项目,你将有机会获得
的firebase美元服务
angularfire用于数据存储和认证发。你可以在这里注册一个免费的 帐户。
医生有一个火力快速入门,指南, 完整的API参考对于angularfire。
我们也有一个教程为了帮助你开始angularfire。
加入我们发角谷歌集团问问题,提供反馈和共享应用程序你建立了与angularfire。
如果你想为angularfire,你需要运行下面的命令来让你的 环境设置:
$ git clone https://angularfire.git 美元/ firebase github.comCDangularfire#去angularfire目录NPM安装- G咕噜CLI美元繁重的任务#全球安装转轮$ NPM安装#安装本地NPM制造/测试的依赖关系为繁重的安装#安装服务器端对端测试硒咕噜看美元#看源文件的变化
咕噜看注意观察变化的Src的/ /目录和皮棉,连接,和缩小
源文件发生变化时。输出文件—angularfire.js和angularfire.min.js-
写入/距离/目录咕噜看也将重新运行单元测试,每一次你
更新任何源文件。
你可以运行整个测试套件通过命令行使用繁重的测试。只有运行单元
测试运行咕噜:单元测试。只运行端到端量角器测试运行咕噜:端到端的测试。
##EN
AngularFire is the officially supported AngularJS binding for Firebase. Firebase is a backend service that provides data storage, authentication, and static website hosting for your Angular app.
AngularFire is a complement to the core Firebase client. It provides you with three Angular services:
$firebaseObject- synchronized objects$firebaseArray- synchronized collections$firebaseAuth- authentication, user management, routing
In order to use AngularFire in your project, you need to include the following files in your HTML:
<!-- AngularJS -->
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.0/angular.min.js"></script>
<!-- Firebase -->
<script src="https://cdn.firebase.com/js/client/2.4.0/firebase.js"></script>
<!-- AngularFire -->
<script src="https://cdn.firebase.com/libs/angularfire/1.2.0/angularfire.min.js"></script>Use the URL above to download both the minified and non-minified versions of AngularFire from the Firebase CDN. You can also download them from the releases page of this GitHub repository. Firebase and Angular libraries can be downloaded directly from their respective websites.
You can also install AngularFire via npm and Bower and its dependencies will be downloaded automatically:
$ npm install angularfire --save$ bower install angularfire --saveOnce you've included AngularFire and its dependencies into your project, you will have access to
the $firebase service.
AngularFire uses Firebase for data storage and authentication. You can sign up here for a free account.
The Firebase docs have a quickstart, guide, and full API reference for AngularFire.
We also have a tutorial to help you get started with AngularFire.
Join our Firebase + Angular Google Group to ask questions, provide feedback, and share apps you've built with AngularFire.
If you'd like to contribute to AngularFire, you'll need to run the following commands to get your environment set up:
$ git clone https://github.com/firebase/angularfire.git
$ cd angularfire # go to the angularfire directory
$ npm install -g grunt-cli # globally install grunt task runner
$ npm install # install local npm build / test dependencies
$ grunt install # install Selenium server for end-to-end tests
$ grunt watch # watch for source file changesgrunt watch will watch for changes in the /src/ directory and lint, concatenate, and minify the
source files when a change occurs. The output files - angularfire.js and angularfire.min.js -
are written to the /dist/ directory. grunt watch will also re-run the unit tests every time you
update any source files.
You can run the entire test suite via the command line using grunt test. To only run the unit
tests, run grunt test:unit. To only run the end-to-end Protractor
tests, run grunt test:e2e.