Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

docpad-plugin-cpuprofiler

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

docpad-plugin-cpuprofiler

Creates cpu snapshots for specified start and stop events in docpad, viewable in the chrome profiler

  • 2.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

CPU profiler Plugin for DocPad

NPM version Dependency Status Gittip donate button Analytics

Generates cpu snapshots using v8-profiler during specified docpad events that can be loaded in to the chrome profiler. Snapshot files are generated in the root of docpad under 'snapshots' folder by default

Config

plugins:
  cpuprofiler:
    # default output path relative to the docpad root path
    snapshotPath: "snapshots"

    # events that this plugin can start and stop recording from (change to suit your docpad instance)
    # default settings
    events: [
      {
        start: 'generateBefore',  # event to start recording
        stop:'generateAfter',     # event to stop recording
        recordSamples: false      # passes the record_samples (flame data) boolean flag to the profiler, default is false
      }
    ]

Capturing Multiple Events Example

plugins:
  cpuprofiler:
    # default output path relative to the docpad root path
    snapshotPath: "snapshots"

    events: [
      {start: 'generateBefore',               stop:'generateAfter'},
      {start: 'parseBefore',                  stop:'parseAfter'},
      {start: 'populateCollectionsBefore',    stop:'populateCollections'},
      {start: 'contextualizeBefore',          stop:'contextualizeAfter'},
      {start: 'renderBefore',                 stop:'renderAfter'},
      {start: 'renderCollectionBefore',       stop:'renderCollectionAfter'},
      {start: 'writeBefore',                  stop:'writeAfter'},
      {start: 'serverBefore',                 stop:'serverAfter'}
    ]

Capture across events

plugins:
  cpuprofiler:
    # default output path relative to the docpad root path
    snapshotPath: "snapshots"
    events: [
      {start: 'generateBefore',               stop:'writeAfter'}
    ]
Some of the events that can be specified
  'generateBefore'
  'generateAfter'
  'parseBefore'
  'parseAfter'
  'populateCollectionsBefore'
  'populateCollections'
  'contextualizeBefore'
  'contextualizeAfter'
  'renderBefore'
  'renderAfter'
  'renderCollectionBefore'
  'renderCollectionAfter'
  'writeBefore'
  'writeAfter' # (default)
  'serverBefore'
  'serverAfter'

Full event list is here

Tips

Good advice here:

History

You can discover the history inside the History.md file

Contributing

You can discover the contributing instructions inside the Contributing.md file

License

Licensed under the incredibly permissive MIT License
Copyright © 2015+ Stringz Solutions Ltd
Copyright © 2015+ Peter Flannery

Keywords

FAQs

Package last updated on 08 Sep 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc