Instantly share code, notes, and snippets.

Code sweet code

Marcin Warpechowski warpech

View GitHub Profile
View index.html
<!DOCTYPE html>
<meta charset="utf-8"/>
<title>Noop that returns</title>
<script src=""></script>
<script src="./suite.js"></script>
<h1>Open the console to view the results</h1>
View Convert.cs
using System;
using System.Linq;
//Usage examples:
//star Convert.cs 6513
//star Convert.cs Blx
//Warning: the output goes to Starcounter Administrator
  1. Accordion. A list that can have a single item or multiple items expanded to show more detail.
  2. Alphabetic indices. Renders the characters in a culture’s alphabet in standard order (e.g., as a vertical or horizontal strip). If supplied with a set of strings, the UI will disable those characters which are not found as the initial character of any string.
  3. Async operation button. A button whose caption changes to reflect an operation in progress (e.g., changing from “Sign In” to “Signing In...”) until the operation completes.
  4. Auto-complete. A text input field that helps the user quickly enter strings from a known list.
  5. Auto-format. Applies a collection of heuristics for formatting text: adding smart quotes, converts double hyphens to endashes, etc.
  6. Auto-size text box. A text area that expands to contain its text.
  7. Backdrop. Shows a background region of non-interactive elements behind the region’s main contents.
  8. Blog. Shows some or all of the entries in the indicated RSS feed.
  9. Blog headlin

Commit Messages

Commit messages should say why you made a change, not what you changed.

A good commit message has the following:

  • explanation of the problem
  • explanation of the solution
  • reference to the relevant GitHub issue
View script.js
// ==UserScript==
// @name Show labels on GH
// @namespace
// @version 0.1
// @description try to take over the world!
// @author You
// @match*
// @grant none
// ==/UserScript==
View gist:f6722f2dcb2e6b9b418ed835c632575a
<template is="dom-bind">
<starcounter-include view-model="{{model.currentPage}}">
View Master.html
<link rel="import" href="/sys/polymer/polymer.html">
<link rel="import" href="/sys/paper-icon-button/paper-icon-button.html">
<link rel="import" href="/CompositionEditor/elements/compositioneditor-inserter/compositioneditor-inserter.html">
.CompositionEditor-resetbutton {
margin: 0;
padding: 0;
border: 0;
View Current.json
View SentimentHelper.cs
using edu.stanford.nlp.ling;
using edu.stanford.nlp.neural.rnn;
using edu.stanford.nlp.pipeline;
using edu.stanford.nlp.sentiment;
using edu.stanford.nlp.trees;
using edu.stanford.nlp.util;
using java.text;
using java.util;
using Starcounter;
View nodeapp.js
var express = require('express')
var bodyParser = require('body-parser');
var chalk = require('chalk');
var app = express()
app.use(function(req, res, next) {
res.header("Access-Control-Allow-Origin", "*");
res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept, spy-type");