This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//http://stackoverflow.com/a/15328864 | |
public static class StringExtensions | |
{ | |
public static TSelf TrimStringProperties<TSelf>(this TSelf input) | |
{ | |
var stringProperties = input.GetType().GetProperties() | |
.Where(p => p.PropertyType == typeof(string)); | |
foreach (var stringProperty in stringProperties) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Modules | |
var gulp = require('gulp'); | |
var sass = require('gulp-sass'); | |
//File Paths | |
var scssFilePath = "./Path/To/scss/**/*.scss"; | |
var cssOutputPath = "./Path/To/css"; | |
// Sass Build Task | |
gulp.task('css', function(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
public class IcoSphereCreator | |
{ | |
private struct TriangleIndices | |
{ | |
public int v1; | |
public int v2; | |
public int v3; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Place your key bindings in this file to overwrite the defaults | |
[ | |
{ "key": "ctrl+shift+s", "command": "workbench.action.files.saveAll" } | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@function isInt($value) { | |
@if round($value) == $value and unitless($value) { | |
@return true; | |
} | |
@return false; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function nl2p($string) { | |
$paragraphs = ''; | |
//split copy into pragraphs | |
foreach (explode("\n", $string) as $line) { | |
//trim line and if it isn't empty, add to output | |
if ($line = trim($line)) { |
NewerOlder