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

surfandscan

v1.2.1

Published

Framework to use scan devices in your browser

Downloads

24

Readme

SurfAndScan

Overview and Client

Edologic Logo

SurfAndScan is a Framework that allow you to use scan devices from the browser. A minimalist web framework for node, vue and every other javascript project. The Framework handles the API from the surfAndScan Client.

Install SurfAndScanClient (For Windows or MacOS)

On Windows you need to install the windows setup. Extract the zip and double click the installer file.

On MacOs you need to install the dmg setup. Not available yet. Try again later.

NPM Version NPM Downloads Linux Build Mac Build Windows Build

####At first import the framework

import sas from 'surfandscan'

####How to check SurfAndScan is installed on host The request starts with

var onSuccess = function(data) {
  console.log('sas is installed');
};
var onError = function(xhr, status, error) {
  console.log('sas is not running or not installed. Please download');
};
sas.checkIsAvailable(onSuccess, onError)


####How to get the available scan devices
The request starts with
```js
var onSuccess = function(data) {
  console.log(data);
};
var onError = function(xhr, status, error) {
  console.error(xhr, status, error);
};
sas.getDevices(onSuccess, onError)

The response in onSuccess

[
  {
    "id": "d_ICA_Dell C2665dnf Color MFP",
    "name": "Dell C2665dnf Color MFP",
    "type": "ICA"
  }
]]

####How to start the scan process The request starts with

var onSuccess = function(data) {
  console.log(data);
};
var onError = function(xhr, status, error) {
  console.error(xhr, status, error);
};
var parameter = {
  duplex:false,
  feederUnit: 0,
  deviceAddress: 'd_ICA_Dell C2665dnf Color MFP'
}
sas.scan(onSuccess, onError, parameter)

The response in onSuccess with actual scan status informations

{
  "id": "task3441595979362720.992698398762",
  "status": "starting",
  "files": [],
  "pageNo": 0,
  "progress": 0,
  "success": true,
  "message": "",
  "feederUnit": 0,
  "messageCode": 0
}

####How to get scan process status information The request starts with

var onSuccess = function(data) {
  console.log(data);
};
var onError = function(xhr, status, error) {
  console.error(xhr, status, error);
};
var taskId = "task3441595979362720.992698398762"
sas.getTaskStatus(taskId, onSuccess, onError, parameter)

The response in onSuccess with actual scan status information 'status' is set to 'done' when done. You get a list of file ids.

{
  "id": "task3441595979362720.992698398762",
  "status": "done",
  "files": [
    {
      "id": "file584650585869633184.6413714743682",
      "name": "img_0.jpg"
    },
    {
      "id": "file58465239210551744.710738804383254",
      "name": "img_1.jpg"
    },
    {
      "id": "file584654120563940876.8503452494729",
      "name": "img_2.jpg"
    }
  ],
  "pageNo": 3,
  "progress": 0,
  "success": true,
  "message": "Feeder is empty",
  "feederUnit": 0,
  "messageCode": 0
}

####How to download a scan task

var taskId = "task3441595979362720.992698398762";
var filePattern = ""; // empty or an fileName 
var pageOrder = null; // or an array with reordered ids like ["file584654120563940876.8503452494729", "file58465239210551744.710738804383254", "file584650585869633184.6413714743682"]
sas.downloadTaskAsPDF(taskId, filePattern, pageOrder)

####How to delete one page from scan task Simply user the pageOrder parameter and dismiss on id.

I want to test without programming

No problem, install the surfAndScan client and open this demo-site

Installation

This is a javascript module available through the npm registry.

Installation is done using the npm install command:

$ npm install surfandscan

Follow our installing guide for more information or use the demo-site

Features

  • Cross-Browser Support: Chrome, Edge, Firefox and IE
  • Focus on high performance
  • Easy implementation
  • Integrate To Pages Within An Hour
  • Fast Flatbed And ADF Scanning
  • Generates Thumbnails & Upload To Web Servers Directly
  • Multiple output formats: PDF, TIFF, JPEG

Docs & Community

Quick Start

The quickest way to get started with SurfAndScan is to open the website FrameworkTest.

Install the executable. SurfAndScanInstaller.exe

Philosophy

The SurfAndScan philosophy is to provide small, robust tooling for HTTPS servers, making it a great solution for single page applications, web sites, hybrids, or public HTTP APIs. It allows you to enable every https site to connect with an scan device. Twain, ICA, WIA, ..

People

The original author of ScanAndSurf is mebel MatthiasEbel

License

MIT