This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { useState } from "react"; | |
| import logo from "./logo.svg"; | |
| import "./App.css"; | |
| function App() { | |
| const [counter, setCounter] = useState(0); | |
| const increment = () => setCounter(counter + 1); | |
| const decrement = () => setCounter(counter - 1); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Created with https://checklyhq.com/docs/puppeteer-recorder/ | |
| const puppeteer = require('puppeteer'); | |
| (async () => { | |
| const browser = await puppeteer.launch() | |
| const page = await browser.newPage() | |
| const navigationPromise = page.waitForNavigation() | |
| await page.goto('https://demo.front-commerce.com/') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| max="$1" | |
| date | |
| echo "url: $2 | |
| rate: $max calls / second" | |
| START=$(date +%s); | |
| get () { | |
| curl -s -o /dev/null -w %{http_code} --max-time 3 "$1" 2>&1 | tr '\r\n' '\\n' | awk -v date="$(date +'%r')" '{print $0"\n-----", date}' >> /tmp/perf-test.log | |
| } |
OlderNewer