Skip to content

Instantly share code, notes, and snippets.

View ThomasPe's full-sized avatar

Thomas Pentenrieder ThomasPe

View GitHub Profile
@ThomasPe
ThomasPe / ScriptInvokeWebViewExtensions.cs
Last active November 11, 2017 13:12
This is an extension to the XAML WebView for invoking scripts from a ViewModel
public static class WebViewExtensions
{
/// <summary>
/// Using a DependencyProperty as the backing store for Content Uri.  This binding Content Uri.
/// </summary>
public static readonly DependencyProperty InvokeScriptProperty = DependencyProperty.RegisterAttached(
"InvokeScript",
typeof(string),
typeof(WebViewExtensions),
@ThomasPe
ThomasPe / RedStripeDealsCrawler.js
Created April 27, 2016 14:36
A simple Node.js script to crawl the Red Stripe Deals from the Windows Store and saving the app details into a JSON file.
var request = require('request');
var cheerio = require('cheerio');
var fs = require('fs');
var async = require('async');
var zlib = require('zlib');
var dealsUri = "https://www.microsoft.com/en-us/store/collections/redstripedeals/pc";
var baseUri = "http://microsoft.com";
var output = [];
var outputFilename = "redstripedeals.json";