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

webmouse

v0.2.6

Published

Cloud Web Browser

Downloads

66

Readme

WebMouse

WebMouse

Cloud Web Browser

#Requirements

  • NodeJS
  • Python 2.7.9+
  • CasperJS Globally Installed

#Installing Requirements

NodeJS can be downloaded at http://nodejs.org Python can be downloaded at http://python.org

Installing CasperJS globally can be done by typing:

npm install casperjs -g

#Installing WebMouse

npm install webmouse -g

#Introduction

The WebMouse concept is to create a 100% cloud rendered web browsing experience using only your mouse to navigate by clicking on screen shots of any given web page. Much like digital library news readers WebMouse captures images of a given page and displays it to the client. The client may then click on the page to navigate around the web. Each web page request will be rendered as an output image. In short WebMouse allows for decentralized cloud based web browsing while interacting with a static image of any given url.

#WHAT WEBMOUSE DOES

  • Cloud Web Browsing
  • Web Scraping
  • Web Crawling

#USING

WebMouse works as a middleware or a stand-alone server. The easiest way to get started is to start the WebMouse server and point your browser to http://localhost.rocks/

To use the webmouse gui server (The Cloudiest Method) just try starting it with:

webmousegui

Now visit http://localhost.rocks/ in your web browser.

To use webmouse to directly output to the console try:

casperjs webmouse http://www.active9.com/

To use WebMouse as a middleware try:

npm install webmouse --save

Then in your code you can use the following:

var mouse = require('mouse');
var casper = require('casper');

var jsondata = require('./active9test.json')[0];
var webmouse = require('../lib/webmouse.js')(jsondata,mouse,casper,function(data) {
	console.log("Capture Complete.");
});

Jsondata represents a JSON WebMouse command script to control actions via JSON.

Here is an example Jsondata WebMouse script:

[
	{
		"name": "active9",
		"output": "active9.png",
		"start": "http://www.active9.com/",
		"click": "li a",
		"save": {
			"output": "active9.html",
			"select": "*"
		},
		"click": "li a",
		"capture": {
			"output": "active9b.png",
			"select": "body"
		},
		"click_2": "li a",
		"capture_2": {
			"output": "active9c.png",
			"select": "*"
		},
		"exit": true
	}
]

This WebMouse script will run a routine to capture screenshots and scrape html from active9.com.

#HOW IT WORKS

WebMouse at it's core utilizes CasperJS to render and interact with web pages. The given web page is rendered to a base64 encoded jpeg and sent to the browser or saved as a file. In server mode webmouse enables a user to directly interact with WebMouse via the included WebMouse gui. This gui will allow you to type in a url of your choosing and interact with the rendered page. In middleware mode you can create your own custom routines to interact with WebMouse.

#KNOWN ISSUES

  • Mobile device clicks do not register the proper element click on the page due to the mobile viewport.

#CONTRIBUTING

We encourage forking. Feel free to fork & pull your new additions, or bug fixes.

#LICENSE MIT