Mozilla 도움말 검색

고객 지원 사기를 피하세요. 저희는 여러분께 절대로 전화를 걸거나 문자를 보내거나 개인 정보를 공유하도록 요청하지 않습니다. "악용 사례 신고"옵션을 사용하여 의심스러운 활동을 신고해 주세요.

자세히 살펴보기

headless screenshot with delay

  • 2 답장
  • 1 이 문제를 만남
  • 1 보기
  • 최종 답변자: seedsca

more options

I'm trying to write a script that would have firefox take a screenshot from the command line, in headless mode (I think). Only issue is that the site I'm trying to screenshot takes a couple of seconds to finish loading, so I only get a partially loaded screenshot. The only option available on the command line is --window-size...

I can take a screenshot inside the dev console with many more options, including --delay (https://developer.mozilla.org/en-US/docs/Tools/Taking_screenshots), is there any way to replicate these options on the command line?

Any other suggestions to script taking a screenshot of a site with delay added?

I'm trying to write a script that would have firefox take a screenshot from the command line, in headless mode (I think). Only issue is that the site I'm trying to screenshot takes a couple of seconds to finish loading, so I only get a partially loaded screenshot. The only option available on the command line is --window-size... I can take a screenshot inside the dev console with many more options, including --delay (https://developer.mozilla.org/en-US/docs/Tools/Taking_screenshots), is there any way to replicate these options on the command line? Any other suggestions to script taking a screenshot of a site with delay added?

글쓴이 seedsca 수정일시

모든 댓글 (2)

more options

Did you look at Firefox in headless mode?

more options

That's what I meant by "on the command line". Headless would have been a much better way to refer to it :)

In headless mode, there is only the option of setting the viewport size, but nothing else related to screenshots. I'd like to set a delay, just as it's possible inside the dev tools console.