Socket
Socket
Sign inDemoInstall

marty-express

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

marty-express

express.js middleware for Marty.js


Version published
Weekly downloads
2
decreased by-75%
Maintainers
1
Weekly downloads
 
Created
Source

Build Status

express middleware for building isomorphic applications with Marty & react-router.

##Usage

var Marty = require('marty');
var Router = require('react-router');
var RouteHandler = Router.RouteHandler;

var routes = (
  <Route handler={RouteHandler}>
    <Route name='foo' path='/foo/:id' handler={Foo} />
    <Route name='var' path='/bar/:id' handler={Bar} />
  </Route>
);

class IsomorphicApp extends Marty.Application {
  constructor() {
    this.register('userStore', require('./stores/userStore'));
  }
}

var app = express();

app.use(require('marty-express')({
  routes: routes, // required
  application: IsomorphicApp, //required
  body: 'body', // name of local body variable in view, default: body
  state: 'state' // name of local state variable in view, default: state
}));

##Quick start

make bootstrap      #Install all dependencies
make test           #Run tests

##Git Commit Messages

  • Use the present tense ("Add feature" not "Added feature")
  • Use the imperative mood ("Move cursor to..." not "Moves cursor to...")
  • Limit the first line to 72 characters or less
  • Reference issues and pull requests liberally
  • Consider starting the commit message with an applicable emoji:
    • :lipstick: :lipstick: when improving the format/structure of the code
    • :racehorse: :racehorse: when improving performance
    • :non-potable_water: :non-potable_water: when plugging memory leaks
    • :memo: :memo: when writing docs
    • :penguin: :penguin: when fixing something on Linux
    • :apple: :apple: when fixing something on Mac OS
    • :checkered_flag: :checkered_flag: when fixing something on Windows
    • :bug: :bug: when fixing a bug
    • :fire: :fire: when removing code or files
    • :green_heart: :green_heart: when fixing the CI build
    • :white_check_mark: :white_check_mark: when adding tests
    • :lock: :lock: when dealing with security
    • :arrow_up: :arrow_up: when upgrading dependencies
    • :arrow_down: :arrow_down: when downgrading dependencies

(From atom)

##Maintainers

##License

Keywords

FAQs

Package last updated on 27 May 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc