JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 47
  • Score
    100M100P100Q56796F
  • License MIT

Pull ESEA profile data

Package Exports

  • esea-scraper
  • esea-scraper/dist/index.cjs.js
  • esea-scraper/dist/index.esm.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (esea-scraper) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

CodeQL

esea-scraper

A consumable Node package to scrape data from ESEA. Due to ESEAs API being protected by Cloudflare, the best approach is to spin up a headless browser and scrape the API.
Ulixee Hero is used to bypass Cloudflare.

Usage

Install

To start, it's best to run with a local Hero Core, so you should install @ulixee/hero-core as a peer dependency:

npm i esea-scraper @ulixee/hero-core

Later, if you'd like to use a remote Hero Core, you can remove the @ulixee/hero-core peer dependency.

Example Usage

  • Typescript:
import { EseaScraper } from 'esea-scraper';

const esea = new EseaScraper();
await esea.getPlayer('2570455');
  • Javascript:
const eseaScraper = require('esea-scraper');
const esea = new eseaScraper.EseaScraper();
await esea.getPlayer('2570455');

Development

To contribute to the repo, you should install the dependencies of the project.

npm i

In order to verify your code works, you should make a relevant test for it, and check your tests pass using the following command:

npm run test