New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

LiveController

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

LiveController

  • 0.0.1
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Live Controller v0.0.1

Table of Contents

  • Introduction
  • API docs
  • Experimental API docs
  • Examples
  • Tests
  • Contributing
  • Contributors
  • License

Introduction

Live Controller is a tiny, client-side router that uses window.pushState and falls back to regular page refreshes when pushState is not available.

API docs

You can find the API docs in the docs folder.

Experimental API docs

Expelrimental API docs will be made available when any part of the project isn't experimental.

Examples

###Here's an example

var controller = new Controller("/things", function(thing) {

thing.get(function(params) {

}) 

thing.get("/:id", function(params) {

}) 

thing.delete("/:id", function(params) {

})

thing.put("/:id", function(params) {

})

thing.post(function(params) {

})

})

###And here's how you send invoke them

Controller.get("/things")

Controller.get("/things/12")

Controller.delete("/things/42")

Controller.put("/things/42", {"title: "w00t"})

Controller.post("/things", {"title: "w00t"})

Contributing

Ideas, feature requests, bug reports, etc are very welcome.

TODO before releasing this,

  • Can we use something better by someone else?
  • Get rid of http verbs, they dumb
  • fallback for shitty browsers with #!

Contributors

  • Zach Smith @xcoderzach
  • Eugene Butler @EButlerIV

License

MIT Licensed (see LICENSE.txt)

FAQs

Package last updated on 13 Apr 2012

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