1. Install nginx
2. Install minio
3. Install mc client
$ mc mb myminio/static
Bucket created successfully ‘myminio/static’.
/* @flow */ | |
// A simplified representation of types using phantom types (so that we store the Type information both at value and type level) | |
class Type<T> {}; | |
class StringT extends Type<string> {} | |
class NumberT extends Type<number> {} | |
// A schema for a User | |
const User = { | |
name: new StringT(), |
Earlier this year Facebook open sourced its React based rich text editing framework Draft.js. At Facebook it powers status updates, comments & notes. Others used it to build editors matching Medium’s experience.
Together with a whole team of open source contributors I built a plugin architecture on top of Draft.js. In this talk I walk you through the existing plugins and show how you can build your own feature-rich text editor for the web with only a handful lines of code. 🤓
Testing React components seems simple at first. Then you need to test something that isn't a pure interaction and things seem to break down. These 4 patterns should help you write readable, flexible tests for the type of component you are testing.
I recommend doing all setup in the most functional way possible. If you can avoid it, don't set variables in a
beforeEach
. This will help ensure tests are isolated and make things a bit easier to reason about. I use a pattern
that gives great defaults for each test example but allows every example to override props
when needed:
// https://github.com/deebloo/rxjs-worker | |
var observable = Observable.of([0, 1, 2, 3, 4]); | |
observable | |
.map(function (data) { | |
return data.concat([5, 6, 7, 8, 9]); | |
}) | |
.workerMap(function (data) { | |
return data.concat([10,11,12,13,14]);; | |
}) |
/** | |
* Base contract that all upgradeable contracts should use. | |
* | |
* Contracts implementing this interface are all called using delegatecall from | |
* a dispatcher. As a result, the _sizes and _dest variables are shared with the | |
* dispatcher contract, which allows the called contract to update these at will. | |
* | |
* _sizes is a map of function signatures to return value sizes. Due to EVM | |
* limitations, these need to be populated by the target contract, so the | |
* dispatcher knows how many bytes of data to return from called functions. |
import webpackSimpleConfig from "webpack-simple-config" | |
/* | |
ideas: | |
- simpler config | |
- fix loaders order (imo, more logical order): proof is that every new webpack user don't get this part | |
- no tons of way to provide config via string, query etc | |
- some shortcuts: simple extract, aliases | |
*/ |
Disclaimer 1: Первую которая "про то чего мы достигли" я таки пропустил.
Disclaimer 2: Многие доклады смотрелись и отчёты писались в состоянии алкогольного опьянения.
Сейчас посмотрел Ben Alpert - What Lies Ahead она про то какие идеи они имеют о дальнейшем развитии. И они делят на UX-идеи и DX-идеи. В UX у них:
If you use sass
and css-modules
and want to restyle some base component without changing its code.
(base component already use css-modules and exposes styles
property)
I know two way how to do it.