npm init -y
Create a folder called src and add an empty index.js file. The code that webpack compiles goes in here including any Javascript modules and the main Tailwind file.
// XPath CheatSheet | |
// To test XPath in your Chrome Debugger: $x('/html/body') | |
// http://www.jittuu.com/2012/2/14/Testing-XPath-In-Chrome/ | |
// 0. XPath Examples. | |
// More: http://xpath.alephzarro.com/content/cheatsheet.html | |
'//hr[@class="edge" and position()=1]' // every first hr of 'edge' class |
<!-- https://developers.google.com/maps/documentation/javascript/tutorial#Audience --> | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" /> | |
<style type="text/css"> | |
html{ height:100%; } |
<?php | |
$offset = 0; | |
$count = 50; | |
$domain = $argv[1]; | |
$tagged = isset($argv[2]) ? $argv[2] : false; | |
$api = 'http://' . $domain . '.tumblr.com/api/read/json?debug=1&num=' . $count . ($tagged ? '&tagged=' . $tagged : ''); | |
function scrape ($api, $count, $offset) { |
<?php | |
define('IMGDIR','./img'); | |
require('sites.php'); | |
foreach($sites as $site){ | |
$rss = get_rss('http://'.$site.'.tumblr.com/rss'); | |
if(count($rss)>0){ | |
if(!is_dir(IMGDIR.'/'.$site)){ | |
mkdir(IMGDIR.'/'.$site,0700,true); | |
} |