Skip to content

Instantly share code, notes, and snippets.

View amrigo's full-sized avatar
🎯
Focusing

Ângelo Marcos Rigo amrigo

🎯
Focusing
View GitHub Profile
@cferdinandi
cferdinandi / index.html
Created October 23, 2024 16:33
How to extend a Web Component with Custom Events. Watch the tutorial here: https://youtu.be/fCXUwkei0uk
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Pick at Random</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style type="text/css">
body {
@atomjar
atomjar / product_style
Last active August 13, 2024 11:34
Stylesheet for Vue Mastery's Intro to Vue course
body {
font-family: tahoma;
color:#282828;
margin: 0px;
}
.nav-bar {
background: linear-gradient(-90deg, #84CF6A, #16C0B0);
height: 60px;
margin-bottom: 15px;
@jeffdonthemic
jeffdonthemic / gist:7247654
Last active August 6, 2020 03:56
Passing parameters in an Angular.js Controller to a Resource
<script>
// in the html page
angular.module('config', []).constant('APIKEY',''5250738f97ce29c219000011'');
</script>
myApp.controller('JobsCtrl', ['$scope', 'Jobs', 'APIKEY', function($scope, Jobs, apiKey) {
var promise = Jobs(apiKey).query().$promise;
// do more awesome programming
}
@SeanCannon
SeanCannon / array_flatten.php
Last active June 23, 2025 22:16
PHP array_flatten() function. Convert a multi-dimensional array into a single-dimensional array.
<?php
/**
* Convert a multi-dimensional array into a single-dimensional array.
* @author Sean Cannon, LitmusBox.com | seanc@litmusbox.com
* @param array $array The multi-dimensional array.
* @return array
*/
function array_flatten($array) {
if (!is_array($array)) {