Back to Integrations
Gridsome Integration
Add Pulse to your Gridsome site via the HTML template or a plugin.
Method 1: HTML Template
Edit src/index.html and add the Pulse script to the head section.
src/index.html
<!DOCTYPE html>
<html ${htmlAttrs}>
<head>
${head}
<script
defer
data-domain="your-site.com"
src="https://pulse.ciphera.net/script.js"
></script>
</head>
<body ${bodyAttrs}>
${app}
</body>
</html>Method 2: Server Configuration
Use gridsome.server.js to inject the script programmatically.
gridsome.server.js
module.exports = function (api) {
api.afterBuild(({ queue }) => {
// Script injection logic
})
}For more details, see the Gridsome head management docs.