It looks like you have a comprehensive performance testing script for comparing the performance of two different endpoints, one from Bubble and another custom SaaS endpoint. The script measures latency and error rates, which are crucial metrics in assessing system reliability and responsiveness under load.
Here's an improved version of your script with some minor adjustments to ensure readability and functionality:
javascript1import { http } from 'k6/http'; 2import { check } from 'k6/check'; 3import { Rate } from 'k6/metrics'; 4 5// Metrics for tracking error rates and latency 6const bubbleErrorRate = new Rate('bubble_error_rate'); 7const saasErrorRate = new Rate('saas_error_rate'); 8 9const bubbleLatency = new Measure('bubble_latency', 'milliseconds'); 10const saasLatency = new Measure('saas_latency', 'milliseconds'); 11 12// Headers for API requests 13const headers = { 14 'Content-Type': 'application/json', 15}; 16 17export let options = { 18 scenarios: { 19 load_test: { 20 executor: 'ramping-vus', 21 startVUs: 1, 22 timeFrames: [ 23 { duration: '30s', targetVUs: 5 }, 24 { duration: '60s', targetV 25 26[Read the full article at DEV Community](https://dev.to/johalputt/which-no-code-bubble-vs-saas-which-wins-43in) 27 28--- 29 30**Want to create content about this topic?** [Use Nemati AI tools](https://nemati.ai) to generate articles, social posts, and more.

![[AINews] The Unreasonable Effectiveness of Closing the Loop](/_next/image?url=https%3A%2F%2Fmedia.nemati.ai%2Fmedia%2Fblog%2Fimages%2Farticles%2F600e22851bc7453b.webp&w=3840&q=75)



