npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@rope/server

v0.0.1

Published

Rope server

Downloads

7

Readme

Build Status NPM version

Rope is a public Kite registry with proxy support between kites. Also introduces bi-directional communication between Kites.

Getting Started

Before starting make sure to call npm install and go get github.com/koding/kite if you want to try go example. Then to start Rope server;

 $ npm start

This will start the server on 0.0.0.0:3210 which then you can run one of the node examples (in another terminal session);

 $ node nodes/js/rope-node.js

will create a Rope Node with Node.js, same file also supports browsers which you can try it out with;

 $ open nodes/js/index.html

will load the kite.js bundle and then runs the rope-node.js which will create another Rope Node in the browser this time.

To try another Rope Node in Go this time;

 $ go run nodes/go/rope-node.go

Once ready, you can start playing with nodes by calling run over Rope Server. The best way to do that for now opening Dev Console in your choice of Browser after loading the nodes/js/index.html. Which will connect to Rope Server, identifies itself and will get a list of Kites registered before which you can access from publicKites global variable. There will be another public variable called kite which will allow you to interact with Rope Server. And for an example of usage of run over Rope Server would be (in Dev Console of nodes/js/index.html);

kite.ping

 > kite.tell('run', {
      kiteId: publicKites[0].id,
      method: "kite.ping"
   }).then(console.log.bind(console))

 pong

will ping the first public kite which will end with a simple pong

kite.systemInfo

 > kite.tell('run', {
      kiteId: publicKites[0].id,
      method: "kite.systemInfo"
   }).then(console.log.bind(console))

 {
   diskTotal: 975902848,
   diskUsage: 328007624,
   homeDir: "/Users/rope",
   memoryUsage: 12602589184,
   state: "RUNNING",
   totalMemoryLimit: 17179869184,
   uname: "darwin",
 }

will return the system info from first public kite.

kite.prompt

 > kite.tell('run', {
      kiteId: publicKites[0].id,
      method: "kite.prompt",
      args: ["Your Name? "]
   }).then(console.log.bind(console))

 # on the terminal of first public kite you will see the prompt "Your Name? "

   $ go run nodes/go/rope-node.go

   2017-07-06 01:24:30 [dope] INFO     New listening: 0.0.0.0:49558
   2017-07-06 01:24:30 [dope] INFO     Serving...
   2017-07-06 01:24:30 [dope] INFO     Identify requested!
   2017-07-06 01:24:30 [dope] INFO     Identified as
      8542b5e3-fc67-4c6b-a368-968c12d69357 now!

   Your Name? Gokmen

 # once provided it will return the result to the browser console.
 Gokmen

square

 > kite.tell('run', {
      kiteId: publicKites[0].id,
      method: "square",
      args: [5]
   }).then(console.log.bind(console))

 25

you can check it out the implementations under nodes/{go, js}

License

MIT (c) 2017 Rope