As you scroll down, the % scrolled of the document is calculated and that same % of an SVG <path>
is drawn.
A Pen by Chris Coyier on CodePen.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords | |
ActivityTweet | |
generic_activity_highlights | |
generic_activity_momentsbreaking | |
RankedOrganicTweet | |
suggest_activity | |
suggest_activity_feed | |
suggest_activity_highlights | |
suggest_activity_tweet |
import puppeteer from 'puppeteer' | |
const browser = await puppeteer.launch({ | |
args: [ | |
'--no-sandbox' | |
], | |
timeout: 10000 | |
}) | |
const page = await browser.newPage() | |
function copyStyles(sourceDoc, targetDoc) { | |
Array.from(sourceDoc.styleSheets).forEach(styleSheet => { | |
if (styleSheet.cssRules) { // for <style> elements | |
const newStyleEl = sourceDoc.createElement('style'); | |
Array.from(styleSheet.cssRules).forEach(cssRule => { | |
// write the text of each rule into the body of the style element | |
newStyleEl.appendChild(sourceDoc.createTextNode(cssRule.cssText)); | |
}); |
/** | |
* @file get/set caret position and insert text | |
* @author islishude | |
* @license MIT | |
*/ | |
export class Caret { | |
/** | |
* get/set caret position | |
* @param {HTMLColletion} target | |
*/ |
module.exports = { | |
entry : "./entry.js", | |
output : { | |
path : __dirname, | |
filename : "bundle.js" | |
}, | |
module : { | |
rules : [ | |
{ | |
test : /\.css$/, |
bot_kick; | |
exec gamemode_competitive; | |
mp_free_armor 1; | |
mp_freezetime 3; | |
mp_weapons_allow_map_placed 1; | |
mp_humanteam any; | |
mp_restartgame 1; | |
mp_round_restart_delay 3; | |
mp_roundtime 80250; | |
mp_maxrounds 30; |
<html> | |
<head> | |
<title>API Example</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> | |
<script type="text/javascript"> | |
var accessToken = "<your agent's client access token>"; | |
var baseUrl = "https://api.api.ai/v1/"; |
As you scroll down, the % scrolled of the document is calculated and that same % of an SVG <path>
is drawn.
A Pen by Chris Coyier on CodePen.