Giter VIP home page Giter VIP logo

chalkscrap's Introduction

Scrapper for chalkpad hp

This is a basic chalkpad scrapper and can get

  1. student info
  2. course info
  3. timetable
  4. teacher name

How to run

yarn install

or

npm install

It uses chromium to scrap dynamic data so wait until it is downloaded

now

yarn dev

It will start the scrapper in development mode at localhost

You can config the port from .env file or src/config

NODE_ENV=development
PORT=5000
CONCURRENCY=5

Concurrency is the limit on the number of chromium tabs the scrapper can open at one time

How to scrap data

This Scrapper use socket for un-timed-out network requests, thus it is able to handle any number of users even in heavy traffic

Here is a sample code to send request to scrapper

var  _  =  require('lodash');

var  io  =  require('socket.io-client');
var  socket  =  io.connect("http://localhost:5000",  {
	reconnection:  true
});

const  password  =  'password';
let  id  =  '171198****'
socket.on('connect',  function  ()  {
	console.log('connected to localhost:5000');
	socket.emit('student',{id: id, password:password});
});

run this code and check the server.

If you like this project feel free to contribue

chalkscrap's People

Contributors

kgoel59 avatar

Watchers

James Cloos avatar  avatar

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.