Giter VIP home page Giter VIP logo

headless-examples's Introduction

MDN Web Docs on Github

👋 Welcome, Bienvenida, 欢迎, Bienvenue, いらっしゃいませ, Receber, Добро пожаловать, 환영합니다, მოგესალმებით

github-profile

Welcome to the mdn repository which we use to track MDN team work. The MDN teams public projects are here, where you can view current and upcoming tasks.

This repository is also used for requests and contains issue templates for the following processes:

Invited experts

Joshua Chen

  • GitHub
  • Invited expert: JavaScript

Hidde de Vries

  • GitHub
  • Invited expert: Accessibility

Scott O'Hara

  • GitHub
  • Invited expert: Accessibility

André Jaenisch

Mendy Berger

NOTE: If you wish to nominate someone to be considered as an invited expert, start by filing an issue in this repository.

headless-examples's People

Contributors

chrisdavidmills avatar iqqmut avatar mozilla-github-standards avatar mykmelez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

headless-examples's Issues

Headless Mode Doesn't Support PDF Rendering

I have a requirement to navigate to a PDF URL in Firefox Headless and then enter a search term, but for some reason the PDF never gets loaded or rendered with a screenshot.

Even attempting to use an external JavaScript library to embed a PDF doesn't work.

firefox -headless -screenshot https://www.epa.gov/sites/production/files/2017-12/documents/lcr_federalism_consultation_letter.signed.12_14_17.pdf
firefox -headless -screenshot https://mozilla.github.io/pdf.js/web/viewer.html

Are there any options via Selenium or perhaps with an external PDF viewer that can be used in conjunction with Headless Firefox, to open a PDF URL and then enter a search phrase?

TypeError: firefox.Binary is not a constructor

Any idea?

$ node selenium-test.js
/selenium/selenium-test.js:7
var binary = new firefox.Binary(firefox.Channel.NIGHTLY);
             ^

TypeError: firefox.Binary is not a constructor
    at Object.<anonymous> (/selenium/selenium-test.js:7:14)
    at Module._compile (module.js:662:30)
    at Object.Module._extensions..js (module.js:673:10)
    at Module.load (module.js:575:32)
    at tryModuleLoad (module.js:515:12)
    at Function.Module._load (module.js:507:3)
    at Function.Module.runMain (module.js:703:10)
    at startup (bootstrap_node.js:193:16)
    at bootstrap_node.js:660:3

CODE_OF_CONDUCT.md file missing

As of January 1 2019, Mozilla requires that all GitHub projects include this CODE_OF_CONDUCT.md file in the project root. The file has two parts:

  1. Required Text - All text under the headings Community Participation Guidelines and How to Report, are required, and should not be altered.
  2. Optional Text - The Project Specific Etiquette heading provides a space to speak more specifically about ways people can work effectively and inclusively together. Some examples of those can be found on the Firefox Debugger project, and Common Voice. (The optional part is commented out in the raw template file, and will not be visible until you modify and uncomment that part.)

If you have any questions about this file, or Code of Conduct policies and procedures, please see Mozilla-GitHub-Standards or email [email protected].

(Message COC001)

screenshot local website doesn't work

Hello

I seem to struggle with the screenshot feature when running from the command line.

Things that work flawless:
firefox -headless --screenshot HA_shot.png http://www.google.com
(and other external websites I've tested)

Things that don't seem to work are local websites, examples:

  • firefox -P fubar --screenshot fubar.png http://192.168.0.205:8123/lovelace/0
    (taking screenshot from my home assistant), this just doesn't generate any png file
  • firefox -P fubar --screenshot intern1.png http://localhost:1313/goosst/
    (my hugo site running locally, this generates a .png file but only has a background color)

I mainly want to get the first one working (the second one was just as a test).
Is there a way how to get this working?

Thanks in advance!

System properties:

xx@xx-Latitude-E5250:~$ firefox --version
Mozilla Firefox 69.0

-xx@xx-Latitude-E5250:~$ hostnamectl
Static hostname: stijn-Latitude-E5250
Icon name: computer-laptop
Chassis: laptop
Machine ID: **
Boot ID: **
Operating System: Ubuntu 19.04
Kernel: Linux 5.0.0-27-generic
Architecture: x86-64

Failed to start browser with other os error

const binary = new firefox.Binary('C:/Program Files/Mozilla Firefox/firefox.exe');
binary.addArguments('-headless');
this.driver = new webdriver.Builder()
.forBrowser('firefox')
.setFirefoxOptions(new firefox.Options().setBinary(binary))
.build();

(node:2628) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): SessionNotCreatedError: Failed to start browser C:/Program Files/Mozilla Firefox/firefox.exe: other os error

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.