0.0.13 • Published 9 years ago

hyperweb v0.0.13

Weekly downloads
60
License
-
Repository
github
Last release
9 years ago

HyperWeb Helper Library (H)

This is the library that wraps all those fiddly little services that you need to create a full app.

require("hyperweb").blastOff()

get "/", ->
  "Hello World"

Sending Emails

H.email "danielx@fogcreek.com",
  subject: "Hello from HyperWeb"
  text: "ayy lmao"

Data Store

Setting and getting data is easy.

H.data.set "key", value

H.data.get("key")
.then (value) ->
  console.log value

You can also use the shorthand method

H.data "key", value

H.data "key"
.then (value) ->
  console.log value

Full Key Value Store API App Example

H = require("hyperweb")
H.blastOff()

get "/:name", (name) ->
  # Lookup the value for name from the datastore
  H.data(name)

post "/:name/", (name, data) ->
  # Set name=value in the datastore
  H.data(name, data)

Remote Resouces

H = require("hyperweb")
H.blastOff()

get "/", ->
  H.ajax("http://peopledirectorything.web/duder")
  .then (duder) ->
    duder.interests
0.0.13

9 years ago

0.0.12

10 years ago

0.0.11

10 years ago

0.0.10

10 years ago

0.0.9

10 years ago

0.0.8

10 years ago

0.0.7

10 years ago

0.0.6

10 years ago

0.0.5

10 years ago

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago

0.0.0

10 years ago