Skip to content

Instantly share code, notes, and snippets.

@robertdean
robertdean / ESPHome-YAML-ld2410-esp32.yaml
Created August 20, 2023 15:11 — forked from peyanski/ESPHome-YAML-ld2410-esp32.yaml
Use this code to make your LD2410 sensor to work with ESP32 or ESP8266 board
esphome:
name: ld2410-esp32
friendly_name: ld2410-esp32
esp32:
board: esp32dev
framework:
type: arduino
# Enable logging
@robertdean
robertdean / local-storage.ts
Created June 4, 2018 13:18 — forked from faisalmuhammad/local-storage.ts
Generic Local Storage Class
/**
* Customized HTML5 local storage class with additional functionality.
*/
export class LocalStorage
{
// Public Methods
// -------------------------------------------------------------------------------------- //
/**
* Checks if the browser supports local storage.
* @returns true if the local storage is supported; false otherwise.
@robertdean
robertdean / data.service.ts
Created June 4, 2018 13:18 — forked from faisalmuhammad/data.service.ts
Angular | Parallel API Requests
/**
* @author Muhammad Faisal
* @description Service for getting data.
*/
// Angular Imports
import { Injectable } from '@angular/core';
import { HttpErrorResponse } from '@angular/common/http';
import { forkJoin as observableForkJoin, Observable } from 'rxjs';
@robertdean
robertdean / development-only.directive.ts
Created June 4, 2018 13:18 — forked from faisalmuhammad/development-only.directive.ts
Angular | Development Only Directive
/**
* @author Muhammad FAISAL
* @description Controls the display of html contents only during development mode.
* @example <button development-only>Some Button</button>
*/
// Angular Imports
import { Directive, OnInit, ElementRef, isDevMode } from '@angular/core';
// Define class for the Directive
// Mocked Service
angular.module('mock.users', []).
factory('UserService', function($q) {
var userService = {};
userService.get = function() {
return {
id: 8888,
name: "test user"
}
/* =============================================================
* bootstrap-scrollspy.js v2.0.1
* http://twitter.github.com/bootstrap/javascript.html#scrollspy
* =============================================================
* Copyright 2012 Twitter, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Linq.Expressions;
namespace BetterFacetedSearchAPI
{
class Program
{
.subnav {
margin-bottom: 60px;
width: 100%;
height: 36px;
background-color: #eeeeee; /* Old browsers */
background-repeat: repeat-x; /* Repeat the gradient */
background-image: -moz-linear-gradient(top, #f5f5f5 0%, #eeeeee 100%); /* FF3.6+ */
background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#f5f5f5), color-stop(100%,#eeeeee)); /* Chrome,Safari4+ */
background-image: -webkit-linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* Chrome 10+,Safari 5.1+ */
background-image: -ms-linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* IE10+ */