createDomain(name?)
Creates a domain
Arguments
name
? (string): Domain name
Returns
Domain: New domain
Example
import {createDomain} from 'effector'
const domain = createDomain() // Unnamed domainconst httpDomain = createDomain('http') // Named domain
const statusCode = httpDomain.event('status code')const download = httpDomain.effect('download')const apiDomain = httpDomain.domain('api') // nested domainconst data = httpDomain.store({status: -1})