Skip to content

Instantly share code, notes, and snippets.

View aarongarciah's full-sized avatar
💻
Solving problems so you don't have to

Aarón García Hervás aarongarciah

💻
Solving problems so you don't have to
View GitHub Profile
@aarongarciah
aarongarciah / theme-values.js
Created August 20, 2020 08:57
Getting theme values in CSS-in-JS lib
const Component = styled(
'div',
{
// a. Seamless
backgroundColor: 'primary',
padding: '0 1',
// b. With a prefix
backgroundColor: '$primary',
padding: '$0 $1',
@aarongarciah
aarongarciah / bookmark.link
Last active July 11, 2019 10:47
Hide Google Calendar Event Names
@aarongarciah
aarongarciah / macos-apps.md
Last active January 7, 2020 08:58
macOS Recommended Apps

macOS Recommended Apps

@aarongarciah
aarongarciah / ITCSS.md
Last active September 6, 2022 08:10
▽ Dressing ITCSS - Daniel Fornells Talk
@aarongarciah
aarongarciah / ITCSS.md
Last active March 14, 2024 13:52
▽ Managing CSS Projects with ITCSS - Harry Roberts Talk
@aarongarciah
aarongarciah / battery-api.markdown
Created October 7, 2016 06:28
⚡Battery API 🔋
var scrolling = false;
$(window).on('scroll', function(){
if( !scrolling ) {
scrolling = true;
(!window.requestAnimationFrame)
? setTimeout(autoHideHeader, 250)
: requestAnimationFrame(autoHideHeader);
}
});
@aarongarciah
aarongarciah / system-date.sh
Created July 13, 2016 10:41
Update unix system date
sudo ntpdate -u ntp.ubuntu.com
@aarongarciah
aarongarciah / debounce.js
Created June 2, 2016 22:08
Debounce function
// https://davidwalsh.name/javascript-debounce-function
// Returns a function, that, as long as it continues to be invoked, will not
// be triggered. The function will be called after it stops being called for
// N milliseconds. If `immediate` is passed, trigger the function on the
// leading edge, instead of the trailing.
function debounce(func, wait, immediate) {
var timeout;
return function() {
var context = this, args = arguments;
var later = function() {