Coder Social home page Coder Social logo

angularfun's Introduction

Angular Fun

By Cary Landholt

About

  • This is an attempt to play with the features of AngularJS using a structure to support large client-side applications, leverage the goodness of RequireJS, CoffeeScript, LESS, Grunt and Jasmine.
  • Demonstrates controllers, services, directives, filters, and partials
  • Uses the RequireJS text plugin to include directive partials in the minified output to reduce server requests
  • Uses Jasmine to run unit tests
  • Uses Grunt to put it all together

Prerequisites

  • Must have Git installed
  • Must have node.js (at least v0.8.1) installed with npm (Node Package Manager)
  • Must have CoffeeScript node package installed globally. npm install -g coffee-script
  • Must have Grunt node package installed globally. npm install -g grunt

Install Angular Fun

Enter the following commands in the terminal.

  • git clone git://github.com/CaryLandholt/AngularFun.git
  • cd AngularFun
  • npm install

Compile Angulr Fun

You have three options.

  1. grunt - will compile the app preserving individual files (when run, files will be loaded on-demand)
  2. grunt dev - same as grunt but will watch for file changes and recompile on the fly
  3. grunt prod - will compile using optimizations. This will create one JavaScript file and one CSS file to demonstrate the power of r.js, the build optimization tool for RequireJS. And take a look at the index.html file. Yep - it's minified too.

Run It

  • Navigate to the root of the project
  • grunt server
  • Open the app in your browser to run the app

Making Changes

  • grunt dev will watch for any CoffeeScript (.coffee), Less (.less), or .template file changes. When changes are detected, the files will be linted, compiled, and ready for you to refresh the browser.

Running Tests

  • grunt
  • Open /test/runner.html to run the unit tests using Jasmine.

To-Do

  • Add many more unit tests :(
  • Add more documentation :(
  • Screencasts :)

angularfun's People

Contributors

carylandholt avatar jyounce avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.