Skip to content

Commit

Permalink
Clone rSERVER implementation (#8)
Browse files Browse the repository at this point in the history
* Update package publication config

* Clone rSERVER implementation

* WIP: Unit test setup

* Use .js extension in src imports

* implement e2e test for happy path

* Include src files in distribution for typechecking

* v0.0.2-0

* Generate .d.ts files

* v0.0.2-1

Co-authored-by: Andrew Hyndman <ahyndman@dropbox.com>
  • Loading branch information
ajhyndman and Andrew Hyndman authored Mar 30, 2022
1 parent fed193f commit 3bc7a1a
Show file tree
Hide file tree
Showing 15 changed files with 1,393 additions and 27 deletions.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
{
"name": "@dropbox-performance/ttvc",
"version": "0.0.1-0",
"version": "0.0.2-1",
"description": "Measure Visually Complete metrics in real time",
"repository": "git@github.com:dropbox/ttvc.git",
"license": "Apache-2.0",
"module": "dist/index.js",
"types": "dist/index.d.ts",
"files": [
"dist"
],
Expand Down
2 changes: 1 addition & 1 deletion playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {devices} from '@playwright/test';
* See https://playwright.dev/docs/test-configuration.
*/
const config: PlaywrightTestConfig = {
testDir: './test/specs',
testDir: './test/e2e',
/* Maximum time one test can run for. */
timeout: 30 * 1000,
expect: {
Expand Down
15 changes: 15 additions & 0 deletions src/annotations.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
export const enum AnnotationNameEnum {
// visually complete metrics
VC_IN_VIEWPORT_MUTATION_OBSERVED_COUNT = 'vc_in_viewport_mutation_observed_count',
VC_INTERSECTIONS_SCHEDULED_COUNT = 'vc_intersections_scheduled_count',
VC_MUTATIONS_OBSERVED_COUNT = 'vc_mutations_observed_count',
VC_INTERSECTIONS_OBSERVED_COUNT = 'vc_intersections_observed_count',
VC_TOTAL_MUTATION_CALLBACK_LATENCY_OVERHEAD_MS = 'vc_total_mutation_callback_latency_overhead_ms',
VC_TOTAL_INTERSECTION_CALLBACK_LATENCY_OVERHEAD_MS = 'vc_total_intersection_callback_latency_overhead_ms',
VC_TOTAL_CALLBACK_LATENCY_OVERHEAD_MS = 'vc_total_callback_latency_overhead_ms',
VC_ELEMENTS_SCHEDULED_FOR_OBSERVATION_BUT_NOT_OBSERVED_COUNT = 'vc_elements_scheduled_for_observation_but_not_observed_count',
}

export type AddAnnotationType = (name: string, value: number | boolean | string) => void;

export type AnnotationsType = Map<string, number | boolean | string>;
Loading

0 comments on commit 3bc7a1a

Please sign in to comment.