• Version 1.0.4
  • Published
  • 9.81 kB
  • No dependencies
  • MIT license


npm i chrome-trace-event
yarn add chrome-trace-event
pnpm add chrome-trace-event


A library to create a trace of your node app per Google's Trace Event format.



class Tracer

class Tracer extends ReadableStream {}


    constructor(opts?: TracerOptions);

      method begin

      begin: (fields: Fields) => void;

        method child

        child: (fields: Fields) => Tracer;

          method completeEvent

          completeEvent: (fields: Fields) => void;

            method end

            end: (fields: Fields) => void;

              method flush

              flush: () => void;
              • If in no streamMode in order to flush out the trace you need to call flush.

              method instantEvent

              instantEvent: (fields: Fields) => void;

                method mkEventFunc

                mkEventFunc: (ph: string) => (fields: Fields) => void;


                  interface Event

                  interface Event {}

                    property ph

                    ph?: string;
                    • event phase

                    property pid

                    pid: number;

                      property tid

                      tid: number;

                        property ts

                        ts: number;

                          index signature

                          [otherData: string]: any;

                            interface Fields

                            interface Fields {}

                              property args

                              args?: any;

                                property cat

                                cat?: any;

                                  index signature

                                  [filedName: string]: any;

                                    interface TracerOptions

                                    interface TracerOptions {}

                                      property fields

                                      fields?: Fields | null;

                                        property noStream

                                        noStream?: boolean;

                                          property objectMode

                                          objectMode?: boolean | null;

                                            property parent

                                            parent?: Tracer | null;

                                              Package Files (1)

                                              Dependencies (0)

                                              No dependencies.

                                              Dev Dependencies (4)

                                              Peer Dependencies (0)

                                              No peer dependencies.


                                              To add a badge like this badgeto your package's README, use the codes available below.

                                              You may also use to create a custom badge linking to

                                              • Markdown
                                              • HTML
                                                <a href=""><img src="" alt=""></a>