Skip to content

Commit ecd6ee5

Browse files
committed
Merge branch 'main' into guolau/restore-cli-missing-pages
2 parents 2251e02 + d477a18 commit ecd6ee5

12 files changed

Lines changed: 236 additions & 349 deletions

File tree

api-reference/openapi.json

Lines changed: 3 additions & 3 deletions
Large diffs are not rendered by default.

constructs/overview.mdx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,22 @@
11
---
2-
title: Using Constructs
3-
description: 'Build monitoring infrastructure with reusable TypeScript classes'
2+
title: Using Checkly CLI Constructs
3+
description: 'Build monitoring infrastructure using JavaScript/TypeScript and the Checkly CLI'
44
sidebarTitle: 'Overview'
55
---
66

77
import JsTsNote from '/snippets/js-ts-note.mdx';
88
import ChecklyConfigCodeBlock from '/snippets/checkly-config-example-code-block.mdx';
99

10+
1011
Every resource you create using the [Checkly CLI](/cli/overview/) is represented by a "construct": it's a class you import from `checkly/constructs`,
1112
for instance an `ApiCheck` or `EmailAlertChannel`. A construct is the "as-code" representation of the eventual resource
1213
created / deleted / updated on the Checkly cloud once you run `npx checkly deploy`.
1314

15+
<Tip>
16+
You must install the [Checkly CLI](/cli/overview) before you can use constructs.
17+
</Tip>
18+
19+
Constructs are JavaScript/TypeScript classes that represent your all monitoring resources. Import them from `checkly/constructs` to create checks, alert channels, and other resources in code.
1420

1521
<CodeGroup dropdown>
1622

constructs/quickstarts/browser-check.mdx

Lines changed: 0 additions & 133 deletions
This file was deleted.

constructs/quickstarts/playwright-check.mdx

Lines changed: 0 additions & 141 deletions
This file was deleted.

detect/synthetic-monitoring/playwright-checks/custom-dependencies.mdx

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,17 @@ sidebarTitle: 'Custom Dependencies'
66

77
Use the [Checkly CLI](/cli/) to turn your Playwright tests into globally distributed monitors. Checkly uses your existing `package.json` dependencies and Playwright configuration.
88

9+
<Info>
10+
**Runtime Environment**: Playwright Check Suites run in a Node.js runtime containing your custom dependencies. See the [runtime specification](/platform/runtimes/runtime-specification) for further details.
11+
</Info>
12+
913
## Using JavaScript/Node.js dependencies
1014

1115
Checkly installs dependencies from your `package.json` and lock files. It works with [npm](https://www.npmjs.com/), [yarn](https://yarnpkg.com/), and [pnpm](https://pnpm.io/).
1216

1317
By default, Checkly installs all dependencies (both `dependencies` and `devDependencies`). You can change this setting to install only `devDependencies` in your [account settings](https://app.checklyhq.com/accounts/settings/account/playwright).
1418

19+
1520
```json package.json
1621
{
1722
"dependencies": {
@@ -131,6 +136,28 @@ export default defineConfig({
131136
})
132137
```
133138

139+
## Dependency Caching
140+
141+
Checkly caches installed packages between check runs to speed up execution and reduce installation time. Dependencies are installed once and reused for subsequent runs until your lock files (`package-lock.json`, `pnpm-lock.yaml`, or `yarn.lock`) change.
142+
143+
### How caching works
144+
145+
When dependency caching is enabled:
146+
147+
1. On the first run, Checkly installs all packages from your lock file and stores them in cache
148+
2. On subsequent runs, Checkly checks if your lock file has changed
149+
3. If unchanged, Checkly uses the cached packages, skipping the installation step
150+
4. If changed, Checkly installs packages again and updates the cache
151+
152+
This significantly reduces check execution time, especially for projects with many or large dependencies.
153+
154+
### Cache behavior by location type
155+
156+
**Public Locations**: Dependency caching is **Always ON**.
157+
158+
**Private Locations**: Dependency caching is **OFF by default**. To enable caching and speed up check runs, set `DEPENDENCY_CACHE=CHECKLY_S3` in your [agent configuration](/platform/private-locations/agent-configuration).
159+
160+
134161
## Troubleshooting
135162

136163
### Package not found

0 commit comments

Comments
 (0)