Skip to content

Instantly share code, notes, and snippets.

View robert-neacsu's full-sized avatar
🏠
Working from home

Robert Neacsu robert-neacsu

🏠
Working from home
View GitHub Profile
@craigmdennis
craigmdennis / _tools_fonts.scss
Last active January 25, 2018 16:18
Generated by SassMeister.com.
// ----
// Sass (v3.4.21)
// Compass (v1.0.3)
// ----
$font-name: 'GT-Walsheim';
$font-path: '../fonts/';
$weights: (
400 'Regular',
@aantipov
aantipov / react2ng1.js
Last active October 4, 2022 18:52
A simple way to convert React components into AngularJS components
import React from "react";
import ReactDOM from "react-dom";
import { fromPairs, map, pick } from "ramda";
/**
* Wraps a React component into Angular component. Returns a new Angular component.
*
* Usage: angular.module('some.module').component('newAngularComponent', react2angular(MyReactComponent))
* (the usage is the same as in similar lib https://github.com/coatue-oss/react2angular)
*/
@tunguskha
tunguskha / How to couple Sass and CSS Variables.md
Last active March 19, 2019 22:42
How to couple Sass and CSS Var

How to couple Sass and CSS Var

If you use Sass extension, you can work with CSS variables.

First, let's create our css variable.

\:root
  --MyColor: #5966D2
<img srcset="image-320w.jpg 320w,
image-480w.jpg 480w,
image-800w.jpg 800w"
sizes="(max-width: 320px) 300px,
(max-width: 480px) 440px,
800px"
src="image-800w.jpg" alt="Image">
@dtbaker
dtbaker / wordpress-hook-debug-snippet.php
Created January 6, 2020 00:28
WordPress hook call stack debug
// WordPress hook call stack debug:
$debug = debug_backtrace();
foreach($debug as $item){
echo $item['file'] .':' .$item['line'] .' - '.$item['function'].'()' ."\n";
if(!empty($item['args']) && is_array($item['args']) && isset($item['args'][1]) && is_string($item['args'][1])){
echo ' --- '. $item['args'][1] ."\n";
}
}