Skip to content

Instantly share code, notes, and snippets.

@jeromecoupe
jeromecoupe / webstoemp-gulpfile.js
Last active January 21, 2024 16:28
Gulp 4 sample gulpfile.js. For a full explanation, have a look at https://www.webstoemp.com/blog/switching-to-gulp4/
"use strict";
// Load plugins
const autoprefixer = require("autoprefixer");
const browsersync = require("browser-sync").create();
const cp = require("child_process");
const cssnano = require("cssnano");
const del = require("del");
const eslint = require("gulp-eslint");
const gulp = require("gulp");
@sdurandeu
sdurandeu / gist:80b286cd0c3971576d39
Last active June 13, 2022 13:55
MsBuild: Add custom files in web deploy package
<Target Name="AdditionalFilesForPackage" AfterTargets="CopyAllFilesToSingleFolderForPackage;CopyAllFilesToSingleFolderForMsDeploy">
<ItemGroup>
<AppDataFiles Include="$(MSBuildProjectDirectory)\App_Data\**\*" />
</ItemGroup>
<Copy SourceFiles="@(AppDataFiles)" DestinationFiles="@(AppDataFiles->'$(_PackageTempDir)\App_Data\%(RecursiveDir)%(Filename)%(Extension)')" SkipUnchangedFiles="true" />
</Target>
@ianstormtaylor
ianstormtaylor / trackLink.js
Last active December 15, 2015 00:18
How to track multiple links and add link-specific properties for the event by using a callback method.
@jonnyreeves
jonnyreeves / index.html
Created April 23, 2012 21:38
JavaScript Class Structure using requireJS. The following code shows you how to create a Class definition in one JavaScript file and then import it for use in another; coming from an ActionScript 3 background this (and some of JavaScript specific traits)
<!DOCTYPE html>
<html>
<head>
<script data-main="usage" src="http://requirejs.org/docs/release/1.0.8/comments/require.js"></script>
</head>
<body>
<p>Check your JavaScript console for output!</p>
</body>
</head>