open-index/open-npm huggingface dataset:
npm package: @plato2/impressionist
Description: Impressionist is a JavaScript library that allows you to scrape data in less time.
Author: Rhonal Velasco
Latest version: 0.6.2-beta

# Impressionist

Impressionist is a JavaScript library that allows you to scrape data in less time.

## Powered by:
[![Platosolutions](https://i.ibb.co/w4v9g9d/Plato-Logo.png)](https://www.platosolutions.io)

### Pre-requisites

-   NodeJS version **v14.15.3** or later.
-   Add `"type": "module"` in package.json.  


### Installation

- `npm i @plato2/impressionist`

## Documentation

Please visit [docs.platosolutions.io](https://docs.platosolutions.io/).

## Usage

Impressionist has predefined Puppeteer settings that let you focus on the scraping work instead of complicating with configurations of the browser and pages. The code to be executed in the browser context is organized in such a way that it is easy to know what data we are extracting.

```javascript
import Impressionist from 'impressionist';

Impressionist.execute('https://example.com', async (browser, page) => {
  const result = await page.evaluate( async() => {
      return await collector({
          name: 'h1',
          description: '.overview > p{outerHTML}',
          reviews: elements('{div.reviews > li}*').iterate({
              author: 'span.author',
              body: 'p.description',
              rating: 'span.rating'
          })
      }).call();
  });

  console.log(result);
});
```


Output:

```bash
{
  name: 'Plato Plugin',
  description: '<div class="overview"><h2>Content</h2><p>Content shows detailed information about the plugin.</p></div>',
  reviews: [
    {
      author: "John Doe",
      body: "This is the review body",
      rating: "4.8"
    },
    {
      author: "...",
      body: "...",
      rating: "..."
    },
    {
      author: "...",
      body: "...",
      rating: "..."
    },
    ...
  ] 
}
```
npm package: @platoai/eslint-config
Description: ESLint shareable config for the Plato AI style
Author: Plato AI
Latest version: 0.0.5

# @platoai/eslint-config
[![npm version](https://badge.fury.io/js/%40platoai%2Feslint-config.svg)](https://badge.fury.io/js/%40platoai%2Feslint-config)

> [ESLint](http://eslint.org/) [shareable config](http://eslint.org/docs/developer-guide/shareable-configs.html) for the Plato AI style.

## Installation

```
npm install --save-dev eslint @platoai/eslint-config
```

## Usage

Once the `@platoai/eslint-config` package is installed, you can use it by specifying `@platoai` in the [`extends`](http://eslint.org/docs/user-guide/configuring#extending-configuration-files) section of your [ESLint configuration](http://eslint.org/docs/user-guide/configuring).

```js
{
  "extends": "@platoai",
  "rules": {
    // Additional, per-project rules...
  }
}
```

### Using the `@platoai` config with `eslint:recommended`

There are several rules in the [`eslint:recommended` ruleset](http://eslint.org/docs/rules/) that Plato AI style is not opinionated about that you might want to enforce in your project.

To use Plato AI style in conjunction with ESLint's recommended rule set, extend them both, making sure to list `@platoai` last:

```js
{
  "extends": ["eslint:recommended", "@platoai"],
  "rules": {
    // Additional, per-project rules...
  }
}
```

To see how the `@platoai` config compares with `eslint:recommended`, refer to the [source code of `index.js`](index.js), which lists every ESLint rule along with whether (and how) it is enforced by the `@platoai` config.


## License

Apache-2 © Google