Coder Social home page Coder Social logo

boiler's Introduction

Boiler Node
===========

This is a boilerplate for a node.js application using the MVC file structure.

Mocha
Jade
Stylus
Hiredis
Socket io
Redis
Node-dev

\--app (Node Server Javascript)
|  \--controllers
|  \--models
|  \--views
|  \--helpers
|  \--socket-io.coffee
|
\--assets (Client-side pre-compilation assets)
|  \--javascripts (Client-side coffeescript)
|  |  \--coffeescripts
|  \--stylesheets (SASS, STYLUS, LESS stylesheets)
|
\--dist (Minified files for distribution)
|  \--stylesheets
|  \--javascripts
|  \--images
|
\--bin (Scripts to run -- possibly replace with gruntfile)
|  \--devserver
|  \--test
|  \--watch
|
\--src (Server-side pre-compilation assets)
|  \--build
|     \--app.build.js
|     \--build.sh*
|
\--public (Post compiled scripts)
|  \--stylesheets
|  \--javascripts
|  |  \--vendor (bower directory. .bowerrc = "directory": "assets/javascripts/vendor")
|  \--images
|
\--test
|  \--apps
|  \--models
|  \--_helper.js
|
\--views
|
\--app.js
\--package.json
\--grunt.js

======================================================
COMPASS
======================================================

Create a Gemfile
----------------

$ touch Gemfile

$ gem install bundler (http://gembundler.com)

Specify Gemfile's dependencies:

source "https://rubygems.org"

gem 'compass'
gem 'sass'
gem 'compass_twitter_bootstrap'
gem 'susy'


$ bundle install
$ git add Gemfile Gemfile.lock


Create a config.rb
------------------

# Compass CSS framework config file

require 'susy'
require 'compass_twitter_bootstrap'
# Require any additional plugins here.

project_type = :stand_alone
# Set this to the root of your project when deployed:
http_path = "/"
sass_dir ="assets/stylesheets"
css_dir = "public/stylesheets"
images_dir = "public/images"
fonts_dir = "public/fonts"
javascripts_dir = "public/javascripts"
line_comments = false
preferred_syntax = :sass
output_style = :expanded
relative_assets = true




$ compass create


SCSS to SASS Conversion tip
To easily convert .scss files to .sass files you can use this little bash script:

$ for f in *.scss; do sass-convert -F scss -T sass $f ${f%%.*}.sass; done

To convert all twitter bootstrap .scss files to .sass (with overwrite):

$ for f in stylesheets/compass_twitter_bootstrap/*.scss; do sass-convert -F scss -T sass $f stylesheets_sass/compass_twitter_bootstrap/${f%%.*}.sass; done

$ for f in stylesheets/*.scss; do sass-convert -F scss -T sass $f stylesheets_sass/${f%%.*}.sass; done

Nice and easy :)

===========================================================

===========================================================


boiler's People

Contributors

kapela avatar

Watchers

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