This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const Benchmark = require('benchmark'); | |
| const _ = require('lodash'); | |
| const props = { | |
| className: 'foo', | |
| onClick: () => null, | |
| children: 'bar', | |
| style: { top: 10 }, | |
| relay: {}, | |
| intl: {}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Post { | |
| static Resource = HttpResource; | |
| static resourceConfig = { endpoint: '/posts' }; | |
| @field({ required: true })) | |
| title = 'untitled'; | |
| @field() | |
| text = ''; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Define your components like: | |
| class MyComponent extends React.Component { | |
| static fetchData = (params) => { | |
| // return an action here. | |
| }; | |
| /* ... */ | |
| } | |
| function fetchComponentData(component, store, params) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import decamelize from 'decamelize'; | |
| import { fromGlobalId } from 'graphql-relay'; | |
| import pluralize from 'pluralize'; | |
| import getItem from '../api/getItem'; | |
| const types = {}; | |
| const endpoints = {}; | |
| const getItemOverrides = {}; |
NewerOlder