Skip to content

ldaniels528/socialize

Repository files navigation

Socialized

Socialized is an example of a full-featured application, which has been developed to demonstrate two (of three) distinct use cases for MEANS.js:

  • Using MEANS.js to build a Play application (Scala.js + AngularJS front-end, Play and Scala RESTful backend).
  • Using MEANS.js to build a MEAN application (Scala.js + AngularJS front-end, Node and Scala.js RESTful backend).

Motivations

Learning a new framework or API can be difficult; however, the learning curve can be greatly reduced when one is provided with good examples. I figured what could be better than a full-fledged application as an example! Socialized also has been a great test bed for me in terms of ensuring that most of the features offered by the facade work as advertised.

Building the code

Build Requirements

Building the MEANS.js + Play application distributable (AngularJS frontend, Play backend)

To build the MEANS.js + Play application (distibutable .ZIP) do the following:

$ sbt "project playapp" dist

Running the MEANS.js + Play application (AngularJS frontend, Play backend)

Optionally, you could run the application directly from the sources:

$ sbt "project playapp" run

The above will startup the application on port 9000 by default.

Building the MEANS.js + Node application (AngularJS frontend, Node backend)

Prior to building the code, you need to install the bower and node modules. NOTE: You only need to perform this step once.

$ cd app-nodejs
$ npm install
$ bower install
$ cd ..

Now, you can compile the Scala.js sources to JavaScript by executing the following command:

$ sbt "project nodejs" fastOptJS

Running the MEANS.js + Node application (AngularJS frontend, Node backend)

$ cd ./app-node
$ node ./dev-server.js    

The above will startup the application on port 1337 by default. To listen/bind to a different port. Set the "port" environment variable.

$ export port=8000

Then (re)start the application.

About

A Social networking portal written using Scala, JavaScript and Node

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published