Splendsome brings Famo.us/Angular and Meteor together. Using Splendsome, you get:
- Famo.us seamless cross-device rendering.
- AngularJS modules, directives, controllers, services and scope.
- Meteor distributed realtime collections.
Therefore, you can:
- Create Famo.us components and animations using AngularJS directives.
- Make AngularJS models synchronized worldwide through Meteor's client/cloud platform.
- Focus in the application instead of boilerplate Ajax / REST management using $http, $resource or other.
These libraries are under active development. While it is possible to create powerful and stable apps, some things are expected to change as they move forward.
- Install git
sudo apt-get install git
in Debian/Ubuntu or follow their instructions - Install Meteor
curl https://install.meteor.com | /bin/sh
- Install Meteorite
npm install -g meteorite
- Create a new meteor app using
meteor create myapp
and/or navigate to the root of your new/existing app. - Add ngMeteor package
mrt add ngMeteor
- Add famono package
mrt add famono
- Add splendsome package
mrt add splendsome
To unleash the power of this fantastic combo, you need to:
- Require
splendsome
- Use the angular module
famous.angular
as a dependency of your own angular module - Push your module into ngMeteor
Super easy:
if (Meteor.isClient)
{
require('splendsome');
angular.module('myModule', ['famous.angular']);
ngMeteor.requires.push('myModule');
}
And you can start coding like this right away in your templates:
<template name="hello">
<h1>Hello World!</h1>
<p>{{ greeting }}</p>
<input ng-model="text" />
<p>[[ text ]]</p>
<fa-app style="height: 200px">
<fa-surface fa-background-color="'red'" fa-size="[108, 108]">
Hello world
</fa-surface>
</fa-app>
</template>
In this example you have: