Get another tab with pyppeteer

I often see puppeterr memo

    result_page_future = asyncio.get_event_loop().create_future()
    browser.once(
    |   'targetcreated',
    |   lambda target: result_page_future.set_result(target)
    )

    _link = await page.J('a.hoge')
    await _link.click()

    newtab_page = await (await result_page_future).page()
    await newtab_page.close()

Recommended Posts

Get another tab with pyppeteer
Get started with MicroPython
Get Tweets with Tweepy
Get date with python
Carry over data to another page (tab) with streamlit
Get country code with python
Get table dynamically with sqlalchemy
Get started with Django! ~ Tutorial ⑤ ~
Get Twitter timeline with python
Get started with influxDB + Grafana
Get Youtube data with python
Get information with zabbix api
Get started with Django! ~ Tutorial ⑥ ~
Get thread ID with python
Get started with Python! ~ ② Grammar ~
Get image features with OpenCV
Get stock price with Python
Get home directory with python
Get keyboard events with python
Get Alembic information with Python
Get ranking with Rakuten API
Get video file information with ffmpeg-python
Get started with Python! ~ ① Environment construction ~
Link to get started with python
Get negative reaction time with psychopy.event.getKeys ()
Get reviews with python googlemap api
Get AWS account ID with boto3
Get started with MicroPython (on macOS)
Get web screen capture with python
Get the weather with Python requests 2
[Python] Get economic data with DataReader
How to get started with Python
How to get started with Django
Get Redmine User list with DataFrame
Get motor angles with Python-LEGO Mindstorms
Get started with machine learning with SageMaker
Get started with Python in Blender
Get weather information with Python & scraping