Skip to content

Instantly share code, notes, and snippets.

View TeemoWan's full-sized avatar
🏠
Working from home

wanli TeemoWan

🏠
Working from home
  • Shenyang, Liaoning, China
View GitHub Profile
@TeemoWan
TeemoWan / ReactJS-Server-Side-Rendering.md
Created January 21, 2016 04:47 — forked from koistya/ReactJS-Server-Side-Rendering.md
Server-side Rendering (SSR) for ReactJS / Flux Applications. Setting document.title

Files

The basic structure of a React+Flux application (see other examples)

 - /src/actions/AppActions.js     - Action creators (Flux)
 - /src/components/Application.js - The top-level React component
 - /src/constants/ActionTypes.js  - Action types (Flux)
 - /src/core/Dispatcher.js        - Dispatcher (Flux)
 - /src/stores/AppStore.js        - The main store (Flux)
@TeemoWan
TeemoWan / gist:2775298
Created May 23, 2012 13:43 — forked from shripadk/gist:652819
Express authentication using Redis for session store and Couchdb for database (in coffeescript!)
###
Module dependencies
###
require.paths.unshift "#{__dirname}/lib/support/express-csrf/"
require.paths.unshift "#{__dirname}/lib/support/node_hash/lib/"
express = require 'express'
app = module.exports = express.createServer()
RedisStore = require 'connect-redis'