Code Monkey home page Code Monkey logo

campy's Introduction

Campy is a little itsy bitsy web framework for the Node.JS server system, providing url routing, helpers, a html5 builder similar in design to Markaby and view module, cookie support, and eventually, cookie based signed session handling.

This little critter has been inspired by the mythical Why The Lucky Stiff’s “Camping” framework for ruby, as well as Markaby. It does not aim to be a direct clone however, and diverges in many ways. The aim is that it will be familiar to Camping and Markaby users, while making the best API decisions possible given the javascript environment.

Of particular note, one line in the mootools more included with this, is modified, to make it compatible with DOM-less environments (such as node). The issue was with the base URI.

Of exceptional note, Campy makes use of my load() function for dependancy loading, as defined here:

process.window = process;

// loads files simply
process.prependLoadString = '';
var alreadyLoaded = [];
process.load = function(file) {
  var file = prependLoadString + file;
  if (alreadyLoaded.indexOf(file) != -1) return;
  alreadyLoaded.push(file);

  var prevLoadString = prependLoadString;
  process.prependLoadString = file.slice(0, file.lastIndexOf('/') + 1);
  process.eval('with (process) {\n' + node.fs.cat(file).wait() + "\n}");
  process.prependLoadString = prevLoadString;
}

load('Campy/campy.js');

campy's People

Contributors

beppu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

beppu guniorobot

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.