If you get error:
run npm command gives error "/usr/bin/env: node: No such file or directory
in file watcher
| :root { | |
| --violation-color: red; /* used for clear issues */ | |
| --warning-color: orange; /* used for potential issues we should look into */ | |
| } | |
| /* IMAGES */ | |
| /* | |
| * Lazy-Loaded Images Check | |
| * ==== |
| # Prep dropbox to ignore 'node_modules' in a node project | |
| # 1. Move this script to your node project root; | |
| # 2. Delete the existing 'node_modules' folder; | |
| # 3. Run this script; | |
| # 4. `npm install` as normal; | |
| # 5. Enjoy! | |
| tell application "Finder" | |
| set current_path to container of (path to me) as alias | |
| make new folder at current_path with properties {name:"node_modules"} |
| RewriteRule "(^|/)\.(?!well-known\/)" - [F] |
| /* Customize website's scrollbar like Mac OS | |
| Not supports in Firefox and IE */ | |
| /* total width */ | |
| body::-webkit-scrollbar { | |
| background-color: #fff; | |
| width: 16px; | |
| } | |
| /* background of the scrollbar except button or resizer */ |
| <header> | |
| <video autoplay playsinline muted loop preload poster="https://s3-us-west-2.amazonaws.com/s.cdpn.io/4273/oceanshot.jpg"> | |
| <source src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/4273/ocean-small.webm" /> | |
| <source src="http://thenewcode.com/assets/videos/ocean-small.mp4" /> | |
| </video> | |
| <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 285 80" preserveAspectRatio="xMidYMid slice"> | |
| <defs> | |
| <mask id="mask" x="0" y="0" width="100%" height="100%" > | |
| <rect x="0" y="0" width="100%" height="100%" /> | |
| <text x="72" y="50">OCEAN</text> |
Tip: Use sass-plus to compile Sass and add vendor prefixes automatically: https://www.npmjs.com/package/sass-plus
| /** | |
| * Updates the passed dialog to retain focus and restore it when the dialog is closed. Won't | |
| * upgrade a dialog more than once. Supports IE11+ and is a no-op otherwise. | |
| * @param {!HTMLDialogElement} dialog to upgrade | |
| */ | |
| var registerFocusRestoreDialog = (function() { | |
| if (!window.WeakMap || !window.MutationObserver) { | |
| return function() {}; | |
| } | |
| var registered = new WeakMap(); |
| <?php | |
| /** | |
| * Insert class into body tag for highest level Category or Page. | |
| * | |
| * Pages and Categories with identical slugs get the same class. | |
| * Works on Pages, Posts, and Category achives. | |
| * | |
| * @return string $top_slug Class name for body tag. | |
| */ | |
| function top_cat_or_page_body_class( $class ) { |
| <?php | |
| add_filter('the_content', 'remove_fusion_shortcodes', 20, 1); | |
| function remove_fusion_shortcodes( $content ) { | |
| $content = preg_replace('/\[\/?fusion.*?\]/', '', $content); | |
| return $content; | |
| } | |
| ?> | |
| **Tested with WP All Import and Export** |