Điểm qua xtermjs/chrome-timeline: 15 sao trên GitHub, viết chủ yếu bằng TypeScript. Write performance tests and get timeline profiling data from puppeteer.
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
Write performance tests and get the timeline profiling data from puppeteer (chromium).
Example:
const timeline = require('chrome-timeline').timeline;
timeline(async (runner) => {
// load something in chromium
await runner.page.goto('https://example.com');
// start a timeline profiling
await runner.tracingStart('TRACE_ABC');
// do something in the remote page
await runner.remote((done, window) => {
// this is within remote browser context
some_heavy_stuff_to_be_measured();
// call done when finished (sync variant)
done();
// or async example with setTimeout
setTimeout(done, 10000);
});
// stop the profiling
await runner.tracingStop();
});
By default timeline does a clean startup of a remote puppeteer chromium client,
runs the provided callback and exists the client afterwards.
This behavior can be changed by providing custom options (e.g. connecting to a running remote instance).
timeline returns a promise containing summaries of tracings that were done denoted
by the name ('TRACE_ABC' in the example).
tracingEndOptions: {
// save trace under timeline/<epoch>/runnerId_<epoch>.trace
saveTrace: false,
// create a summary of trace data, also saved if saveTrace=true
createSummary: true,
// report uncommitted changes for current git branch in summary
reportUncommittedChanges: false,
}
Summary
Summaries are returned by timeline for a single tracing, if tracingEndOptions.createSummary=true.
They contain various useful stats from a trace for further postprocessing:
export interface ISummary extends IPostProcess {
// path to trace flie the summary belongs to (empty if tracingEndOptions.saveTrace=false)
traceFile: string;
// name of the trace as given to .tracingStart(name)
traceName: string;
// additional git repo stats (contains {isRepo: false} for non git repo projects)
repo: IRepoInfo;
// puppeteer profiling metadata (e.g. hardware setup, env data, cmdline)
metadata: {[key: string]: any};
// profiling summary as shown in the pie chart in devtools
summary: {[key: string]: number};
// top down tree events
topDown: IEvent[];
// bottom up tree events
bottomUp: IEvent[];
}
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/xtermjs/chrome-timeline là nguồn chính thức.
xtermjs/chrome-timeline có phải mã nguồn mở không?
TopGit chưa ghi nhận license cho xtermjs/chrome-timeline. Phần lớn repo public trên GitHub là mã nguồn mở, nhưng điều khoản khác nhau từng repo — mở file LICENSE để xác nhận.
xtermjs/chrome-timeline là gì?
xtermjs/chrome-timeline (xtermjs/chrome-timeline) là dự án TypeScript trên GitHub. Theo mô tả gốc: Write performance tests and get timeline profiling data from puppeteer.
Đọc đầy đủ README ở tab phía trên.
Muốn nghe thêm một ý kiến về chrome-timeline?
Hỏi một AI đọc được trang này — một cú bấm là có ngay nhận định về chrome-timeline.