-
ikawka
- Canada
- http://ikawka.github.io/
Pinned Loading
-
-
-
-
Human readable filesize
Human readable filesize 1<?php
2function human_filesize($bytes, $decimals = 2) {
3$sz = 'BKMGTP';
4$factor = floor((strlen($bytes) - 1) / 3);
5return sprintf("%.{$decimals}f", $bytes / pow(1024, $factor)) . @$sz[$factor];
-
Global Store with React Context
Global Store with React Context 1/*
2===== store.js =====
3import createStore from '@store'
4const initialState = { foo: 'bar' }
5export const { Provider, connect } = createStore(initialState)
-
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.