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

search-engine-nodejs

v1.0.9

Published

A nodejs module to extract links from Aol, Ask, Baidu,Google, Bing and Yahoo

Downloads

80

Readme

search-engine-nodejs

npm

npm-version issues lisense download-weekly download-times

search-engine-nodejs is made from several search engines namely: Aol, Ask, Baidu, Bing, Google and Yahoo, this search engine is not perfect yet, but if anyone wants to develop it, just continue

Includes

  • fake-useragent
  • request
  • request-promise-native
  • urlencode
  • cheerio

Before Installing

Instalation

Installation is done using the npm install command:

$ npm install search-engine-nodejs

Features

search-engine-nodejs supports the following search engines:

Usage

javascript

create a file name index.js with the following contents

const search_engine = require('search-engine-nodejs').default;

(async () => {
    const options = {
        qs: {
            q: 'Hello Search Engine'
        }
    }

    // you can use: Aol, Ask, Baidu, Bing, Google or Yahoo
    const results = await search_engine.Google(options)
    console.log(results)
})();

Start scraping by firing up the command node index.js

and more or less like this

[
  {
    url: 'https://support.google.com/websearch/forum/AAAAgtjJeM4tswt4Orqfos/?hl=uk',
    title: 'How to switch to Google as my default search engine in MS EDGE ...',
    description: '15.01.16. Rotary Steve. Hello,. Perhaps this search can be helpful.... https://www. microsoft.com/en-us/search/result.aspx?q=default%20search%20engine.'
  },
  ...
  {
    url: 'http://www.proz.com/forum/sdl_trados_support/255884-an_easy_way_to_copy_paste_source_terms_from_trados_studio_into_a_search_engine_or_dictionary.html?text=An%20easy%20way%20to%20copy-paste%20source%20terms%20from%20Trados%20Studio%20into%20a%20search%20engine%20or%20dictionary%3F%20?text=An%20easy%20way%20to%20copy-paste%20source%20terms%20from%20Trados%20Studio%20into%20a%20search%20engine%20or%20dictionary%3F%20(SDL%20Trados%20support)&print=1',
    title: 'An easy way to copy-paste source terms from Trados Studio into a ...',
    description: '10 Sep 2013 - ... 20Trados%20Studio%20into%20a%20search%20engine%20or%20dictionary %3F%20?text=An ... Hello everyone, .... hi Paul, Sep 10, 2013 ...'
  }
]

add the pageOfResult option if you want to get results to 2 or more

(async () => {
    const options = {
        pageOfResult: 2,
        qs: {
            q: 'Hello Search Engine'
        }
    }

    // you can use: Aol, Ask, Baidu, Bing, Google or Yahoo
    const results = await search_engine.Google(options)
    console.log(results)
    // This will display the second results page
})();

Start scraping by firing up the command node index.js

and more or less like this

[
  {
    url: 'https://www.hijden.nl/homepages/digital-agency/',
    title: 'Digital Agency - Hijden - Ontwerp & Branding',
    description: '... 22%2C%22text%22%3A%22Our%20approach%20is%20to%20focus%20on %20growing%20visibility%20in%20organic%20search%20engine%20results.Tidak ada: Hello%'
  },
  ...
  {
    url: 'https://easynewsweb.com/amp/%F0%9F%98%8D-fall-in-love-with-your-search-engine-results-with-25-off-aioseop-pro-%F0%9F%98%8D/',
    title: 'Fall In Love With Your Search Engine Results With 25% Off ...',
    description: "Hey – As Valentine's Day is approaching, we'd like to take this opportunity to ... % 20Fall%20In%20Love%20With%20Your%20Search%20Engine%20Results% ..."
  }
]

Typescript

You just need to change the require to import like this

import SearchEngine from "search-engine-nodejs";

and this is the code

import SearchEngine from "search-engine-nodejs";

(async () => {
    const options = {
        qs: {
            q: 'Hello Search Engine'
        }
    }

    // you can use: Aol, Ask, Baidu, Bing, Google or Yahoo
    const results = await SearchEngine.Google(options)
    console.log(results)
})();

Thank You