Let’s Encrypt is a free, automated, and open Certificate Authority.
- Install tools for using the Let's Encrypt certificates using Certbot
sudo apt-get update \
sudo apt-get install software-properties-common
sudo pacman -S ruby ruby-rdoc gcc make | |
gem update --user-install | |
gem install jekyll --user-install | |
# finally add $HOME/.gem/ruby/2.7.0/bin to your PATH variable |
// source: http://stackoverflow.com/a/11058858 | |
function ab2str(buf) { | |
return String.fromCharCode.apply(null, new Uint16Array(buf)); | |
} |
const useCancellable = fn => { | |
const requestRef = useRef(0) | |
return async (...args) => { | |
// Keep track of latest promise ID | |
const id = Date.now() | |
requestRef.current = id | |
// Wait for resolution | |
const res = await fn(...args) |
function makeStore({ actions }) { | |
// Make a context for the store | |
const context = React.createContext(); | |
// Make a provider that takes an initialValue | |
const Provider = ({ initialValue = {}, children }) => { | |
// Make a new state instance | |
const [state, setState] = useState(initialValue); | |
// Bind the actions with the old state and args |
const useCount = () => { | |
const [{ count }, setState] = useStore(); | |
const increment = () => { | |
setState(old => ({ | |
...old, | |
count: old.count + 1 | |
})); | |
} |
Firstly, Create React App is good. But it's a very rigid CLI, primarily designed for projects that require very little to no configuration. This makes it great for beginners and simple projects but unfortunately, this means that it's pretty non-extensible. Despite the involvement from big names and a ton of great devs, it has left me wanting a much better developer experience with a lot more polish when it comes to hot reloading, babel configuration, webpack configuration, etc. It's definitely simple and good, but not amazing.
Now, compare that experience to Next.js which for starters has a much larger team behind it provided by a world-class company (Vercel) who are all financially dedicated to making it the best DX you could imagine to build any React application. Next.js is the 💣-diggity. It has amazing docs, great support, can grow with your requirements into SSR or static site generation, etc.
/* Customize website's scrollbar like Mac OS | |
Not supports in Firefox and IE */ | |
/* total width */ | |
body::-webkit-scrollbar { | |
background-color: #fff; | |
width: 16px; | |
} | |
/* background of the scrollbar except button or resizer */ |
Enter this in the search box along with your search terms:
Get all gists from the user santisbon.
user:santisbon
Find all gists with a .yml extension.
extension:yml
Find all gists with HTML files.
language:html