• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

microlinkhq / browserless / 36534255521
81%

Build:
DEFAULT BRANCH: master
Ran 29 Sep 2026 07:02AM UTC
Jobs 10
Files 48
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

29 Sep 2026 07:01AM UTC coverage: 80.624% (+0.2%) from 80.471%
36534255521

push

github

web-flow
feat(function): resolve page methods when the snippet asks for them (#950)

* feat(function): resolve page methods when the snippet asks for them

`extendPage` can only carry values decided before the snippet starts, so
anything it might read had to be produced up front, on every run, whether
or not it reached that method.

`hostPage` attaches methods the host resolves at the moment they are
called:

  createFunction(({ page }) => page.content(), {
    hostPage: { content: () => fetchThePage(url) }
  })

Nothing is serialized into the isolate. The call travels over the
`isolated-function` channel when the snippet makes it, so a snippet that
returns without touching `page` resolves nothing, and neither does a
branch it does not take:

  async ({ page }) => (false ? await page.content() : 'skipped')

That last case is the one static inspection cannot answer, because
whether the call happens is only known at runtime.

A `hostPage` key satisfies its method exactly as an `extendPage` key
does, so `needsBrowser` sees both and a snippet reading only these still
skips Chromium. Both kinds can sit on the same page; host methods are
applied first so an eager value with the same name wins, matching the
existing precedence where extendPage shadows a real page method.

Requires isolated-function 0.2.10 for the channel.

8 tests, including the untaken branch, the coexistence of both kinds, and
that a host method never reaches `pageValues`.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* docs(function): run the hostPage examples and say what crosses the channel

Both examples built a function and never called it, so neither produced
the result its comment claimed. They now await the call, and the output
was checked by running them: the first resolves the html with one host
call, the second returns "skipped" with none.

"Nothing is serialized into the isolate" was wrong about the part that
matters. The method stays on the host, but its argument... (continued)

1379 of 1623 branches covered (84.97%)

Branch coverage included in aggregate %.

71 of 73 new or added lines in 3 files covered. (97.26%)

5911 of 7419 relevant lines covered (79.67%)

67891.75 hits per line

Uncovered Changes

Lines Coverage ∆ File
2
92.06
0.69% packages/function/src/template.js
Jobs
ID Job ID Ran Files Coverage
1 @browserless/goto - 36534255521.1 29 Sep 2026 07:05AM UTC 7
76.05
GitHub Action Run
2 browserless - 36534255521.2 29 Sep 2026 07:03AM UTC 3
80.38
GitHub Action Run
3 @browserless/ai - 36534255521.3 29 Sep 2026 07:03AM UTC 6
73.14
GitHub Action Run
4 @browserless/screenshot - 36534255521.4 29 Sep 2026 07:03AM UTC 12
73.7
GitHub Action Run
5 @browserless/screencast - 36534255521.5 29 Sep 2026 07:02AM UTC 1
96.08
GitHub Action Run
6 @browserless/function - 36534255521.6 29 Sep 2026 07:03AM UTC 3
94.76
GitHub Action Run
7 @browserless/capture - 36534255521.7 29 Sep 2026 07:02AM UTC 11
86.63
GitHub Action Run
8 @browserless/devices - 36534255521.8 29 Sep 2026 07:03AM UTC 1
95.41
GitHub Action Run
9 @browserless/lighthouse - 36534255521.9 29 Sep 2026 07:03AM UTC 3
97.83
GitHub Action Run
10 @browserless/errors - 36534255521.10 29 Sep 2026 07:02AM UTC 1
99.45
GitHub Action Run
Source Files on build 36534255521
  • Tree
  • List 48
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #36534255521
  • 50bf0368 on github
  • Prev Build on master (#36390576218)
  • Next Build on master (#36680244787)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc