Skip to content

Instantly share code, notes, and snippets.

View developerantoniosousa's full-sized avatar
🏠
Working from home

Antonio Sousa developerantoniosousa

🏠
Working from home
View GitHub Profile
@developerantoniosousa
developerantoniosousa / web-camera-stream.html
Created June 6, 2021 20:18
How to get camera stream and show it on the web page
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Camera</title>
<style>
* {
margin: 0;
padding: 0;
@developerantoniosousa
developerantoniosousa / Pessoa.php
Created February 24, 2020 22:57
Singleton with PHP
<?php
class Pessoa {
private $name;
private function __construct() {}
public static function getInstance() {
static $instance = null;
if (is_null($instance)) $instance = new Pessoa;
return $instance;
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="/Users/antoniosousa/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
{
"workbench.colorTheme": "Dracula",
"workbench.iconTheme": "material-icon-theme",
"editor.fontFamily": "Fira Code",
"editor.formatOnSave": true,
"editor.fontLigatures": true,
"editor.fontSize": 14,
"editor.rulers": [
80,
120