Skip to content

Instantly share code, notes, and snippets.

View boyney123's full-sized avatar
💭
Making Stuff

David Boyne boyney123

💭
Making Stuff
View GitHub Profile
{
"extends": "lighthouse:full",
"settings": {
"budgets": [
{
"resourceSizes": [
{
"resourceType": "script",
"budget": 50
},
# Add annotations in grafana
curl -X POST \
https://{YOUR_URL}/api/annotations \
-H "authorization: Bearer $GRAFANA_API_TOKEN" \
-H 'content-type: application/json' \
-d "{
\"text\": \"Hello world!\",
\"tags\": [ \"deployment\", \"env:dev}\", \"application:my-application\", \"commit: commit-sha-example}\"]
}"
# Lines starting with '#' are comments.
# Each line is a file pattern followed by one or more owners.
# These owners will be the default owners for everything in the repo.
* @defunkt
# Order is important. The last matching pattern has the most precedence.
# So if a pull request only touches javascript files, only these owners
# will be requested to review.
*.js @octocat @github/js
@boyney123
boyney123 / AngularOdometer.js
Last active July 1, 2021 22:12
odometer.js - Angular Directive Example
//Directive
angularApp.directive('angularOdometer', function () {
return {
restrict: 'A',
link: function(scope, element, attrs) {
//Creates new instance of odometer for the element
new Odometer({el: element[0], value: scope[attrs.odometer]});
//Watch for changes and update the element value (causing odometer to redraw)