Giter Club home page Giter Club logo

puppeteer's Introduction

Headless Chrome on Google App Engine

This sample application demonstrates how to use Headless Chrome via the Puppeteer module to take screenshots of webpages on Google App Engine Node.js standard environment.

Running and deploying

Refer to the appengine/README.md file for instructions on running and deploying.


Hotel Price and Room Search

This application is mainly developed to help search for Hotels and book the best room with lowest price on the listing. There is a lot more depending on application,you can send to the database.

    
    ...
        var database = firebase.database();

        // [START browser]
        const browser = await puppeteer.launch({
            args: ['--no-sandbox'],
            headless: true
        });
        // [END browser]
        const page = await browser.newPage();
        await page.setViewport({
            width: 1000,
            height: 900
        });
    ...
  

You have a browser instance that runs on the server and it's termed Headless because you don't get to see the Chrome browser but it will be gathering data on the background.

You have to close the browser when you are done with the search, to reduce service costs on Google App Engine.

    ...
        
     await browser.close();

    ...

The Writer

Legend_of_theHeroGenius

puppeteer's People

Contributors

thandoncube1 avatar

Stargazers

 avatar  avatar

Watchers

 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.