Image we have the following code:
<script>
var TOKEN="abcdef";
</script>| <!-- | |
| InfiniteScroll.svelte | |
| Author: Tom Barrasso | |
| Licensed to the Apache Software Foundation (ASF) under one | |
| or more contributor license agreements. See the NOTICE file | |
| distributed with this work for additional information | |
| regarding copyright ownership. The ASF licenses this file | |
| to you under the Apache License, Version 2.0 (the |
| service: my-api | |
| org: CompanyName | |
| # You can pin your service to only deploy with a specific Serverless version | |
| # Check out our docs for more details | |
| # frameworkVersion: "=X.X.X" | |
| frameworkVersion: '>=2.1.1 <3.0.0' | |
| custom: | |
| defaultStage: dev |
| #EXTM3U | |
| #EXTINF:-1,TELEMUNDO | |
| http://iphone-streaming.ustream.tv/ustreamVideo/21733416/streams/live/playlist.m3u8 | |
| #EXTINF:0,TELEMUNDO | |
| http://iphone-streaming.ustream.tv/ustreamVideo/21733416/streams/live/playlist.m3u8 | |
| #EXTINF:-1,UNIVISION | |
| http://iphone-streaming.ustream.tv/ustreamVideo/21680354/streams/live/playlist.m3u8 | |
| #EXTINF:0,UNIVISION 1 |
| Description: Deploys lambda functions to forward cloudwatch logs to logstash | |
| Parameters: | |
| coreNetworkingStackName: | |
| Type: String | |
| Resources: | |
| lambdaRole: | |
| Type: "AWS::IAM::Role" | |
| Properties: |
| from __future__ import print_function | |
| import re | |
| import urllib | |
| import boto3 | |
| from botocore.vendored import requests | |
| s3 = boto3.client('s3') | |
| pattern = re.compile(r'(?P<owner>\S+) (?P<bucket>\S+) \[(?P<time>.*)\] (?P<ip>\S+) (?P<requester>\S+) (?P<reqid>\S+) (?P<operation>\S+) (?P<key>\S+) (?P<request>"[^"]*") (?P<status>\S+) (?P<error>\S+) (?P<bytes>\S+) (?P<size>\S+) (?P<totaltime>\S+) (?P<turnaround>\S+) (?P<referrer>"[^"]*") (?P<useragent>"[^"]*") (?P<version>\S)') |
| /* All of our custom controls should be what we expect them to be */ | |
| input, | |
| textarea { | |
| -webkit-box-sizing:content-box; | |
| -moz-box-sizing:content-box; | |
| box-sizing:content-box; | |
| } | |
| /* | |
| Show overflow in Edge |
| Apache License | |
| Version 2.0, January 2004 | |
| http://www.apache.org/licenses/ | |
| TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION | |
| 1. Definitions. | |
| "License" shall mean the terms and conditions for use, reproduction, | |
| and distribution as defined by Sections 1 through 9 of this document. |
| //npm init -y | |
| //npm install --save puppeteer | |
| //usage: node script.js /path/to/input.html /path/to/output.pdf | |
| //script.js | |
| const puppeteer = require('puppeteer'); | |
| (async () => { | |
| "use strict"; | |
| // animation utils | |
| // =============== | |
| const trackTime = id => { | |
| const [entry] = performance.getEntriesByName(id); | |
| if (!entry) { | |
| performance.mark(id); |