| <!-- |
| Copyright 2020 The Chromium Authors |
| Use of this source code is governed by a BSD-style license that can be |
| found in the LICENSE file. |
| --> |
| <!DOCTYPE html> |
| <html lang="en"> |
| <head> |
| <meta charset="utf-8"> |
| <title>Document</title> |
| <meta name="viewport" content="width=device-width,initial-scale=1"> |
| <style> |
| body { |
| background-color: #F0F0F0; |
| } |
| </style> |
| </head> |
| <body> |
| <div id="div1"> |
| The time is: <span id="span1"></span> |
| </div> |
| <script> |
| function getTime() { |
| const date = new Date(); |
| return date.getHours() + ':' + date.getMinutes() + ':' + date.getSeconds() + ':' + date.getMilliseconds(); |
| } |
| |
| const el = document.getElementById('span1'); |
| |
| // Log some messages to the console. |
| console.log(el); |
| console.log(getTime()); |
| |
| // Generate some script activity for the performance tool. |
| function updateTime() { |
| const time = getTime(); |
| el.innerHTML = time; |
| |
| setTimeout(updateTime, 0); |
| } |
| updateTime(); |
| |
| // Generate some entries in the issues panel. |
| document.cookie = 'foo=bar;samesite=None'; |
| </script> |
| </body> |
| </html> |