{"id":13395415,"url":"https://github.com/joelgriffith/navalia","last_synced_at":"2025-03-13T20:32:15.755Z","repository":{"id":57308969,"uuid":"95808074","full_name":"joelgriffith/navalia","owner":"joelgriffith","description":"A bullet-proof, fast, and reliable headless browser API","archived":true,"fork":false,"pushed_at":"2018-07-24T17:25:36.000Z","size":2708,"stargazers_count":957,"open_issues_count":17,"forks_count":35,"subscribers_count":27,"default_branch":"master","last_synced_at":"2024-04-14T11:49:41.732Z","etag":null,"topics":["automation","browser","chrome","graphql","headless","headless-chrome","typescript"],"latest_commit_sha":null,"homepage":"https://joelgriffith.github.io/navalia/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/joelgriffith.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-29T18:35:02.000Z","updated_at":"2024-02-21T15:08:37.000Z","dependencies_parsed_at":"2022-08-29T12:40:59.805Z","dependency_job_id":null,"html_url":"https://github.com/joelgriffith/navalia","commit_stats":null,"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joelgriffith%2Fnavalia","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joelgriffith%2Fnavalia/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joelgriffith%2Fnavalia/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joelgriffith%2Fnavalia/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/joelgriffith","download_url":"https://codeload.github.com/joelgriffith/navalia/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243478474,"owners_count":20297267,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","browser","chrome","graphql","headless","headless-chrome","typescript"],"created_at":"2024-07-30T17:01:57.414Z","updated_at":"2025-03-13T20:32:15.324Z","avatar_url":"https://github.com/joelgriffith.png","language":"TypeScript","funding_links":[],"categories":["TypeScript","Browser automation","Deprecated  (a-z↓)"],"sub_categories":[],"readme":"\u003cimg src=\"./assets/logo-color.png\" alt=\"Navalia Logo\" style=\"text-align: center;\" width=\"300\" \u003e\n\n[![npm version](https://badge.fury.io/js/navalia.svg)](https://badge.fury.io/js/navalia)\n[![Build Status](https://travis-ci.org/joelgriffith/navalia.svg?branch=master)](https://travis-ci.org/joelgriffith/navalia)\n[![dependencies Status](https://david-dm.org/joelgriffith/navalia/status.svg)](https://david-dm.org/joelgriffith/navalia)\n[![styled with prettier](https://img.shields.io/badge/styled_with-prettier-ff69b4.svg)](https://github.com/prettier/prettier)\n\n# DEPRECATION WARNING: Unfortunately it's time for me to deprecate this library as I cannot give it the time it needs. If you're interested in maintaining this lib, send me message (joel at joelgriffith dot net). I'd recommend using something like chromeless or puppeteer if possible. Thanks!\n\nThe bullet-proof, fast, and most feature-rich Chrome driver around. Navalia lets you interact with Chrome and run parallel work with ease. Not using JavaScript? There's a GraphQL server that you can use to communicate with over HTTP allowing any runtime to drive Chrome.\n\n- [📝 View the library documentation here](https://joelgriffith.github.io/navalia/)\n- [🎨 Looking for test inspiration? Navalia uses itself for tests.](./integration/api.test.ts)\n\n## Features\n\n- Scrape webpage data, even from JavaScript-heavy sites.\n- Run automated functional tests.\n- Discover visual regressions in your site.\n- Capture screenshots, pdfs, execute javascript, insert text, and more.\n- The largest API for interacting with Chrome.\n\n## GraphQL Front-end\n\nSimply run `navalia` with a specified port e.g.\n\n```bash\n$ npm i -g navalia\n$ navalia --port 4000\n```\n\n![NavaliaQL](./assets/NavaliaQL.gif)\n\n## Recipes\n\n- [Functional Testing](https://codeburst.io/composable-end-to-end-tests-for-react-apps-2ec82170af62)\n- [Website Code Coverage](https://codeburst.io/capturing-unused-application-code-2b7594a9fe06)\n- [Visual Regression Testing](https://codeburst.io/automatic-visual-regression-testing-23cc06471dd)\n\n## Usage\n\nThe API for interacting with a browser is simple and chainable. You can call all methods individually and `await`/`then` the resulting value, or chain multiple together and collect their responses in a single result.\n\n*Chaining*\n\n```js\nconst { Chrome } = require('navalia');\nconst chrome = new Chrome();\n\nchrome\n  .goto('https://amazon.com')\n  .type('input', 'Kindle')\n  .click('.buy-now')\n  .end()\n  .then((responses) =\u003e {\n    console.log(responses); // ['https://www.amazon.com/', true, true, true]\n  });\n```\n\n*Await*\n\n```js\nimport { Chrome } from 'navalia';\nconst chrome = new Chrome();\n\nasync function buyItOnAmazon() {\n  const url = await chrome.goto('https://amazon.com');\n  const typed = await chrome.type('input', 'Kindle');\n  const clicked = await chrome.click('.buy-now');\n\n  chrome.done();\n\n  console.log(url, typed, clicked); // 'https://www.amazon.com/', true, true\n}\n\nbuyItOnAmazon();\n```\n\n## Roadmap\n\nIn no particular order, this is the vision of navalia going forward:\n\n- [X] Expanded browser API (pdf rendering, network watching, more).\n- [ ] Bring more vendors onto the framework.\n- [ ] Better typings around externals with no @type support.\n- [X] Parameterization on killing long-running jobs.\n- [ ] Unit testing all features.\n- [ ] Integration testing with the various vendors so our API's don't break when theirs do.\n- [X] Travis, coveralls, greenkeeper, and other handy-dandy tools to automate chore tasks.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoelgriffith%2Fnavalia","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoelgriffith%2Fnavalia","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoelgriffith%2Fnavalia/lists"}