path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
examples/generator-react-webpack/src/components/run.js | demones/react-guide | import 'core-js/fn/object/assign';
import React from 'react';
import ReactDOM from 'react-dom';
import App from './Main';
// Render the main component into the dom
ReactDOM.render(<App />, document.getElementById('app'));
|
node_modules/react-bootstrap/es/FormGroup.js | NathanBWaters/jb_club | import _extends from 'babel-runtime/helpers/extends';
import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from ... |
packages/react-server-examples/bike-share/components/network-card.js | lidawang/react-server | import PropTypes from 'prop-types';
import React from 'react';
import {logging, Link} from 'react-server';
const logger = logging.getLogger(__LOGGER__);
const NetworkCard = ({id, name, location, company}) => {
logger.info(`rendering card for network ${name}`);
return (
<div><Link path={`/network?network=${id}`}>{... |
client/canx-client/src/views/Help.js | uros-stegic/canx | import React from 'react'
function Help(props) {
return (
<div>
<h1 className='profile-title'>HELP1</h1>
<p className='help-paragraph'>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam consectetur nibh felis, vitae consequat leo accumsan quis. Maecenas et metus sem. Proin porttitor o... |
SplashScreen.js | ganny26/angularUI | import React from 'react';
import { StyleSheet, Text, View,Button,Alert } from 'react-native';
import {NavigationActions} from 'react-navigation';
export default class SplashScreen extends React.Component {
componentDidMount(){
}
componentDidUpdate(){
}
render() {
return (
<View style={style... |
host/CSV.js | xeejp/chicken-race | import React from 'react'
import { connect } from 'react-redux'
import {Card, CardActions, CardHeader, CardTitle, CardText} from 'material-ui/Card';
import TextField from 'material-ui/TextField'
const mapStateToProps = ({ started, users }) => {
return {
started,
users
}
}
function jsonToCsv(json, header,... |
React_Redux/weather_search/src/components/header.js | awg3/LearnCodeImprove | import React from 'react';
export default (props) => {
return(
<header>
<h1 className="text-center">
Weather Search
</h1>
</header>
);
}
|
todo-app/src/Hello.js | iproduct/course-node-express-react | import React from 'react';
class Hello extends React.Component {
render() {
return <div>Hello {this.props.name}, from React.js!</div>;
}
}
export default Hello;
|
src/containers/ByShops/ByShops.js | marinbgd/coolbeer | import React from 'react';
import {connect} from 'react-redux';
import PropTypes from 'prop-types';
import {bindActionCreators} from 'redux';
import * as actions from './ByShops.actions';
import {find} from 'lodash';
import {cyan500} from 'material-ui/styles/colors';
import {
CircularProgress,
FontIcon,
Avatar,
... |
app/javascript/mastodon/features/compose/components/upload.js | foozmeat/mastodon | import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import IconButton from '../../../components/icon_button';
import Motion from '../../ui/util/optional_motion';
import spring from 'react-motion/lib/spring';
import ImmutablePureComponent from 'react... |
src/signed-uploader.js | navjobs/upload | import React from 'react';
import Request from './request';
export default class Uploader extends React.Component {
constructor() {
super();
this.state = {};
}
handleFiles(files) {
this.setState({ files });
if (this.props.uploadOnSelection) this.handleUpload(files);
}
componentWillUnmount()... |
src/icons/LibraryAddIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class LibraryAddIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M8 12H4v28c0 2.21 1.79 4 4 4h28v-4H8V12zm32-8H16c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h24c2.21 0 4-1.... |
www/app/index.js | benmratner/react-boilerplate | import React from 'react';
import ReactDOM from'react-dom';
import routes from './config/routes';
import {BrowserRouter} from 'react-router-dom'
ReactDOM.render(
<BrowserRouter>
{routes}
</BrowserRouter>,
document.getElementById('app')); |
src/redux/utils/createDevToolsWindow.js | raineroviir/SUWProject | import React from 'react'
import ReactDOM from 'react-dom'
import { Provider } from 'react-redux'
import DevTools from '../../containers/DevToolsWindow'
export default function createDevToolsWindow (store) {
const win = window.open(
null,
'redux-devtools', // give it a name so it reuses the same window
`... |
tests/flow/react_modules/es6class-types-module.js | arijs/prettier-miscellaneous | /* @flow */
import React from 'react';
type Props = {name: string};
class Hello extends React.Component<{}, Props, void>{
props: Props;
static defaultProps: {};
render(): React.Element<*> {
return <div>{this.props.name}</div>;
}
}
module.exports = Hello;
|
assets/js/components/app.js | joshgagnon/sailjs-webpack-base | import React from 'react';
import Header from './header';
import Login from './login';
import { pureRender } from '../utils';
import { connect } from 'react-redux';
import { requestUserInfo } from '../actions';
import { pushState, replaceState } from 'redux-router';
import DropZone from 'react-dropzone';
import { creat... |
docs/app/Examples/elements/Button/Types/ButtonExampleLabeledIcon.js | Rohanhacker/Semantic-UI-React | import React from 'react'
import { Button } from 'semantic-ui-react'
const ButtonExampleLabeledIcon = () => (
<div>
<Button content='Pause' icon='pause' labelPosition='left' />
<Button content='Next' icon='right arrow' labelPosition='right' />
</div>
)
export default ButtonExampleLabeledIcon
|
node_modules/react-icons/io/social-hackernews-outline.js | bairrada97/festival |
import React from 'react'
import Icon from 'react-icon-base'
const IoSocialHackernewsOutline = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m32.5 7.5h-25v25h25v-25z m2.5-2.5v30h-30v-30h30z m-11.8 7.4h3.5l-5 9.4v5.6h-3.1v-5.6l-5.2-9.4h3.7l3.1 6.6z"/></g>
</Icon>
)
export default IoSoci... |
src/svg-icons/communication/phonelink-erase.js | igorbt/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let CommunicationPhonelinkErase = (props) => (
<SvgIcon {...props}>
<path d="M13 8.2l-1-1-4 4-4-4-1 1 4 4-4 4 1 1 4-4 4 4 1-1-4-4 4-4zM19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0... |
src/modules/Sequencer/components/NoteGrid/Row/Cell/index.js | ruebel/synth-react-redux | import React from 'react';
import PropTypes from 'prop-types';
import styled from 'styled-components';
import Color from 'color';
const colors = ['#73aade', '#fbd490', '#2cb87e', '#de73aa'];
const onColor = '#672e9b';
const getColor = (beat, note, on, hover = false) => {
const hasNote = note && note.velocity > 0;
... |
src/svg-icons/device/usb.js | igorbt/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceUsb = (props) => (
<SvgIcon {...props}>
<path d="M15 7v4h1v2h-3V5h2l-3-4-3 4h2v8H8v-2.07c.7-.37 1.2-1.08 1.2-1.93 0-1.21-.99-2.2-2.2-2.2-1.21 0-2.2.99-2.2 2.2 0 .85.5 1.56 1.2 1.93V13c0 1.11.89 2 2 2h3v3.... |
src/svg-icons/action/update.js | mtsandeep/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionUpdate = (props) => (
<SvgIcon {...props}>
<path d="M21 10.12h-6.78l2.74-2.82c-2.73-2.7-7.15-2.8-9.88-.1-2.73 2.71-2.73 7.08 0 9.79 2.73 2.71 7.15 2.71 9.88 0C18.32 15.65 19 14.08 19 12.1h2c0 1.98-.88 4.5... |
packages/components/src/DateTimePickers/InputTimePicker/TimePicker.stories.js | Talend/ui | import React from 'react';
import { action } from '@storybook/addon-actions';
import InputTimePicker from './InputTimePicker.component';
import TimePicker from '../pickers/TimePicker';
export default {
title: 'Form/Controls/DatePicker/Time',
decorators: [
story => (
<form
onSubmit={event => {
event.p... |
vertex_ui/src/components/Tooltip/Tooltip.js | zapcoop/vertex | import React from 'react';
import { PropTypes } from 'prop-types';
import { Tooltip as ReactBootstrapTooltip } from 'react-bootstrap';
import ReactDOM from 'react-dom';
import _ from 'underscore';
import { Colors } from './../../consts';
import bsStyleToColor from './../utils/bsStyleToColor';
/*
Extended ReactBo... |
pages/content-delivery-network.js | markhker/newCyK |
import React, { Component } from 'react';
import './scss/service-single.scss';
import Link from '../components/Link';
import Card from 'material-ui/lib/card/card';
import CardTitle from 'material-ui/lib/card/card-title';
import CardText from 'material-ui/lib/card/card-text';
import MyRawTheme from '../components/the... |
app/Components/Search/Search.js | KevinAngeles/nytreact | import 'react-dates/initialize';
import React, { Component } from 'react';
import moment from "moment";
import { SingleDatePicker } from 'react-dates';
import 'react-dates/lib/css/_datepicker.css';
import isInclusivelyAfterDay from 'react-dates/src/utils/isInclusivelyAfterDay';
moment.locale('en');
const displayFormat... |
src/app/containers/App/index.js | mike182uk/xbl-friends | import React from 'react'
import { connect } from 'react-redux'
import DevTools from '../../containers/DevTools'
import AppError from '../../components/AppError'
import AppMainNav from '../../components/AppMainNav'
import {
AUTH as AUTH_ROUTE
} from '../../constants/routes'
import styles from './styles.css'
const... |
src/routes/Home/components/SlideshowLayout/Slideshow.js | chozandrias76/responsive-sesame-test | import React from 'react'
import { IndexLink, Link } from 'react-router'
import PropTypes from 'prop-types'
import { Well, DropdownButton, MenuItem, ButtonToolbar, SplitButton } from 'react-bootstrap'
import './Slideshow.scss'
export const Slideshow = ({ children }) => (
<div className='slideshow-container'>
<di... |
src/svg-icons/action/zoom-out.js | barakmitz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionZoomOut = (props) => (
<SvgIcon {...props}>
<path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 ... |
js/profile/home/PreferredGenderScreen.js | kilimondjaro/react-native-couchsurfing-app | // @flow
import React from 'react';
import {
View,
ScrollView,
StyleSheet,
Navigator
} from 'react-native';
import {connect} from 'react-redux';
import {CSHeader} from '../../components/CSHeader';
import CSInputList from '../../components/CSInputList';
import CSCheckCell from '../../components/CSCheckCell';
imp... |
src/post/postSingle/PostSingleComments.js | Sekhmet/busy | import React, { Component } from 'react';
import { FormattedMessage } from 'react-intl';
import CommentFormEmbedded from '../../comments/CommentFormEmbedded';
import Comments from '../../comments/Comments';
import './PostSingleComments.scss';
export default class PostSingleComments extends Component {
constructor(pr... |
static/sptrader.js | joequant/sptrader | import React from 'react';
import ReactDOM from 'react-dom';
import {Tabs, Tab, ButtonToolbar, Button, FormControl,
FormGroup, ControlLabel, HelpBlock, Modal,
Form,Checkbox} from 'react-bootstrap';
import {AgGridReact} from 'ag-grid-react';
import LoginForm from './login-form';
import ConnectionTable from './tables/c... |
src/svg-icons/action/eject.js | nathanmarks/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionEject = (props) => (
<SvgIcon {...props}>
<path d="M5 17h14v2H5zm7-12L5.33 15h13.34z"/>
</SvgIcon>
);
ActionEject = pure(ActionEject);
ActionEject.displayName = 'ActionEject';
ActionEject.muiName = 'Svg... |
packages/node_modules/@ciscospark/react-component-confirmation-modal/src/index.js | Altocloud/alto-react-ciscospark | import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import styles from './styles.css';
export default function ConfirmationModal(props) {
const {
title,
actionButtonLabel,
cancelButtonLabel,
body
} = props;
const modalClassNames = classNames(`cisc... |
pootle/static/js/admin/general/components/LiveEditor.js | pavels/pootle | /*
* Copyright (C) Pootle contributors.
*
* This file is a part of the Pootle project. It is distributed under the GPL3
* or later license. See the LICENSE file for a copy of the license and the
* AUTHORS file for copyright and authorship information.
*/
import React from 'react';
import _ from 'underscore';
im... |
node_modules/rc-tabs/es/InkTabBarMixin.js | yhx0634/foodshopfront | import _defineProperty from 'babel-runtime/helpers/defineProperty';
import { setTransform, isTransformSupported } from './utils';
import React from 'react';
import classnames from 'classnames';
export function getScroll(w, top) {
var ret = w['page' + (top ? 'Y' : 'X') + 'Offset'];
var method = 'scroll' + (top ? 'T... |
example/App/index.js | in-flux/react-component-router | import React from 'react';
import {useValue} from '../../src';
import {A} from '../A';
import {Menu} from '../Menu';
import {Home} from './Home';
import {Foo} from './Foo';
import {Bar} from './Bar';
import css from './App.css';
export function App() {
const page = useValue('page');
return (
<div className={... |
src/routes/contact/Contact.js | SOCLE15/carpoule | /**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-present Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import React from 'react';
import PropTypes from 'prop-... |
web/react/src/client/components/locs/GridContainer/Hero/HeroTextContainer/HeroFooter/HeroFooter.js | JamesMillercus/Portfolio-Website | import React, { Component } from 'react';
import { connect } from 'react-redux';
import HeroSubChars from './HeroSubChars/HeroSubChars';
import { fetchCurrentFooterChars } from './../../../../../../actions';
import './assets/scss';
class HeroFooter extends Component {
heroFooter(activeHeroText, selectedItem) {
... |
src/Component.js | marcelaraujo/react-component-template | import React from 'react';
const Component = React.createClass({
render() {
return <div>Component</div>;
}
});
export default Component;
|
src/Parser/Druid/Restoration/Modules/Items/T20_4Set.js | hasseboulen/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import SpellIcon from 'common/SpellIcon';
import SpellLink from 'common/SpellLink';
import { formatPercentage } from 'common/format';
import Analyzer from 'Parser/Core/Analyzer';
import Combatants from 'Parser/Core/Modules/Combatants';
import HealingDon... |
src/svg-icons/image/collections-bookmark.js | verdan/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageCollectionsBookmark = (props) => (
<SvgIcon {...props}>
<path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 10l-2.5-1.5L15 12V4h5v8z"/>... |
browser/reducer.js | smanwaring/relationship-visualizer | import React from 'react';
import { combineReducers } from 'redux';
import relationships from './components/relationships/relationships.reducer';
import selectedRelationship from './components/relationships/selectedRelationship.reducer';
import activities from './components/activities/activities.reducer';
import logged... |
MARVELous/client/src/js/components/characterDetails/commentBox.js | nicksenger/StackAttack2017 | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { postCharacterComment } from '../../actions/index';
export class CommentBox extends Component {
constructor(props) {
super(props);
this.state = {
body: ''
};
thi... |
client/extensions/woocommerce/woocommerce-services/components/number-field/number-input.js | Automattic/woocommerce-connect-client | /** @format */
/**
* External dependencies
*/
import React, { Component } from 'react';
import PropTypes from 'prop-types';
/**
* Internal dependencies
*/
import FormTextInput from 'components/forms/form-text-input';
export default class NumberInput extends Component {
static propTypes = {
onChange: PropTypes... |
src/browser/auth/SignInPage.js | chad099/react-native-boilerplate | // @flow
import type { State } from '../../common/types';
import Email from './Email';
import React from 'react';
import SignInError from './SignInError';
import Social from './Social';
import linksMessages from '../../common/app/linksMessages';
import { Box, Loading, PageHeader } from '../../common/components';
import... |
docs/app/Examples/modules/Embed/Types/EmbedExampleVimeo.js | aabustamante/Semantic-UI-React | import React from 'react'
import { Embed } from 'semantic-ui-react'
const EmbedExampleVimeo = () => (
<Embed
id='125292332'
placeholder='/assets/images/vimeo-example.jpg'
source='vimeo'
/>
)
export default EmbedExampleVimeo
|
examples/huge-apps/routes/Messages/components/Messages.js | arbas/react-router | import React from 'react';
class Messages extends React.Component {
render () {
return (
<div>
<h2>Messages</h2>
</div>
);
}
}
export default Messages;
|
.storybook/config.js | LestaD/InstaClone | import React from 'react'
import styled, { injectGlobal } from 'styled-components'
import { normalize } from 'styled-normalize'
import { configure, addDecorator, setAddon } from '@storybook/react'
import { withKnobs } from '@storybook/addon-knobs'
import { setOptions } from '@storybook/addon-options'
import backgrounds... |
test/helpers/shallowRenderHelper.js | GigHubAccount/gallery-by-react | /**
* Function to get the shallow output for a given component
* As we are using phantom.js, we also need to include the fn.proto.bind shim!
*
* @see http://simonsmith.io/unit-testing-react-components-without-a-dom/
* @author somonsmith
*/
import React from 'react';
import TestUtils from 'react-addons-test-utils'... |
examples/js/custom/toolbar/custom-button-group.js | AllenFang/react-bootstrap-table | /* eslint max-len: 0 */
/* eslint no-unused-vars: 0 */
/* eslint no-alert: 0 */
import React from 'react';
import { BootstrapTable, TableHeaderColumn, ButtonGroup } from 'react-bootstrap-table';
const products = [];
function addProducts(quantity) {
const startId = products.length;
for (let i = 0; i < quantity; i... |
example/react-native-camera-roll-picker/camera-roll-picker.js | olofd/react-native-photos-framework | import React, { Component } from 'react';
import {
CameraRoll,
Platform,
StyleSheet,
View,
Text,
ListView,
ActivityIndicator
} from 'react-native';
import ImageItem from './ImageItem';
import RNPhotosFramework from '../react-native-photos-framework';
import { postAssets } from '../react-native-photos-fram... |
src/lib/plot/horizontal-grid-lines.js | jameskraus/react-vis | // Copyright (c) 2016 Uber Technologies, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge... |
src/Parser/Monk/Windwalker/Modules/Spells/FistsofFury.js | hasseboulen/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import SpellLink from 'common/SpellLink';
import SpellIcon from 'common/SpellIcon';
import Combatants from 'Parser/Core/Modules/Combatants';
import Analyzer from 'Parser/Core/Analyzer';
import StatisticBox, { STATISTIC_ORDER } from 'Main/StatisticBox';
... |
packages/material-ui-icons/src/FormatItalic.js | cherniavskii/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<g><path d="M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z" /></g>
, 'FormatItalic');
|
source/router.js | simonewebdesign/npm-strap | import React from 'react';
import page from 'page';
export default class Router extends React.Component {
// Since we are going to deal with routes inside componentDidMount the initial
// load of our component won't have this.state.component yet, so let's set a
// default value for that.
constructor(props) {
... |
src/client/assets/javascripts/components/NotFound/NotFound.js | dark-dao/strimmer-test | import React, { Component } from 'react';
import { Link } from 'react-router';
export default class NotFound extends Component {
render() {
return (
<div className="container text-center">
<h1>Шел бы ты отсюда, петушок</h1>
<hr />
<Link to="/">Ухожу</Link>
</div>
);
}
}
|
app/components/Navbar/PrintNav.js | barbalex/kapla3 | import React from 'react'
import { NavItem, Glyphicon } from 'react-bootstrap'
import { observer, inject } from 'mobx-react'
import compose from 'recompose/compose'
const onClickPrint = () => {
// https://github.com/electron/electron/blob/master/docs/api/web-contents.md#contentsprintoptions
/**
* PROBLEM
* w... |
app/common/post/PostItem.js | in42/internship-portal | import React from 'react';
import { Card, Table, Icon } from 'semantic-ui-react';
import { Link } from 'react-router-dom';
import PropTypes from 'prop-types';
import Axios from 'axios';
import Auth from '../../auth/modules/Auth';
import User from '../../auth/modules/User';
import './styles.scss';
function formatDate(d... |
src/components/ChallengeButton/ChallengeButton.js | RetroGameNight/rgn-ui | /*
* Retro Game Night
* Copyright (c) 2015 Sasha Fahrenkopf, Cameron White
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import './ChallengeButton.less'
import React from 'react'
import FluxComponent from 'flummox/component'
im... |
app/components/ListItem/index.js | stephme/react-specly | import React from 'react';
import Item from './Item';
import Wrapper from './Wrapper';
function ListItem(props) {
return (
<Wrapper>
<Item>
{props.item}
</Item>
</Wrapper>
);
}
ListItem.propTypes = {
item: React.PropTypes.any,
};
export default ListItem;
|
server/sonar-web/src/main/js/apps/web-api/components/Search.js | Builders-SonarSource/sonarqube-bis | /*
* SonarQube
* Copyright (C) 2009-2016 SonarSource SA
* mailto:contact AT sonarsource DOT com
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 3 of the License... |
index.android.js | MikeKoval/react-native-motivate-app | import 'es6-symbol/implement';
import {Provider} from 'react-redux';
import store from './src/redux/store';
import AppViewContainer from './src/modules/AppViewContainer';
import React from 'react';
import {AppRegistry, BackAndroid} from 'react-native';
import * as NavigationStateActions from './src/modules/navigation/N... |
docs/src/app/components/pages/components/Stepper/HorizontalLinearStepper.js | nathanmarks/material-ui | import React from 'react';
import {
Step,
Stepper,
StepLabel,
} from 'material-ui/Stepper';
import RaisedButton from 'material-ui/RaisedButton';
import FlatButton from 'material-ui/FlatButton';
/**
* Horizontal steppers are ideal when the contents of one step depend on an earlier step.
* Avoid using long step ... |
src/components/App.js | Bryukh/random_figures | import React from 'react'
import ActiveCanvas from '../containers/ActiveCanvas';
const App = () => (
<div>
<ActiveCanvas />
</div>
);
export default App |
src/index.js | mbchoa/react-ecosystem | import React from 'react';
import ReactDOM from 'react-dom';
import { AppContainer } from 'react-hot-loader';
import App from './components/App';
ReactDOM.render(
<AppContainer>
<App />
</AppContainer>,
document.getElementById('root')
);
if (module.hot) {
module.hot.accept();
}
|
src/components/Reply/Reply.js | townmi/ReactExamples |
import React, { Component } from 'react';
import axios from 'axios';
import { Link } from 'react-router';
class Reply extends Component {
constructor(props) {
super(props);
}
render() {
const replyInfo = this.props.info;
const index = this.props.replyIndex;
const... |
src/svg-icons/image/hdr-strong.js | spiermar/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageHdrStrong = (props) => (
<SvgIcon {...props}>
<path d="M17 6c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zM5 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 ... |
packages/mcs-lite-ui/src/Button/Button.example.js | MCS-Lite/mcs-lite | import React from 'react';
import styled, { ThemeProvider } from 'styled-components';
import { storiesOf } from '@storybook/react';
import { action } from '@storybook/addon-actions';
import { withInfo } from '@storybook/addon-info';
import { kindList, darken1, darken2, darken3 } from 'mcs-lite-theme';
import { IconLoad... |
examples/todomvc/index.js | zalmoxisus/remote-redux-devtools | import 'babel-polyfill';
import React from 'react';
import { render } from 'react-dom';
import { Provider } from 'react-redux';
import App from './containers/App';
import configureStore from './store/configureStore';
import 'todomvc-app-css/index.css';
const store = configureStore();
render(
<Provider store={store}... |
js/Editor.js | tmn/tMD | import React from 'react';
import omniscient from 'omniscient';
const component = omniscient.withDefaults({
jsx: true
});
const mixins = {
handleChange: function (event) {
this.props.cursor.cursor('editor').update(() => {
return event.currentTarget.value;
});
}
};
const Editor = component('Editor... |
src/ButtonInput.js | zanjs/react-bootstrap | import React from 'react';
import Button from './Button';
import FormGroup from './FormGroup';
import InputBase from './InputBase';
import childrenValueValidation from './utils/childrenValueInputValidation';
class ButtonInput extends InputBase {
renderFormGroup(children) {
let {bsStyle, value, ...other} = this.p... |
client/Splash/SplashView.js | PicDrop/PicDrop | import React from 'react';
import FlatButton from 'material-ui/lib/flat-button';
import RaisedButton from 'material-ui/lib/raised-button';
class SplashView extends React.Component {
render() {
return (
<div id="splashview">
<div className="intro-header">
<div className="container">
... |
src/js/components/Form/stories/FieldWithChildren.js | HewlettPackard/grommet | import React from 'react';
import {
Box,
Button,
CheckBoxGroup,
Form,
FormField,
Grommet,
MaskedInput,
RadioButtonGroup,
RangeInput,
Select,
TextArea,
TextInput,
} from 'grommet';
import { grommet } from 'grommet/themes';
const passwordRulesStrong = [
{
regexp: new RegExp('(?=.*?[A-Z])')... |
src/components/Navigation/TopNavbar.js | strongharris/Dashboard | import React from 'react';
import { Link } from 'react-router-dom';
const TopNavbar = () => {
return (
<header id="header" >
<div className="headerbar">
<div className="headerbar-left">
<ul className="header-nav header-nav-options">
<li className="header-nav-brand" >
... |
pages/index.js | stoille/madlib | require('@risingstack/trace');
import Head from 'next/head'
import React from 'react'
import ReactDOM from 'react-dom'
import {Editor, EditorState, RichUtils, Modifier} from 'draft-js'
import NoSSR from 'react-no-ssr'
class PlainTextEditorExample extends React.Component {
constructor (props) {
super(props)
t... |
src/svg-icons/action/launch.js | w01fgang/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionLaunch = (props) => (
<SvgIcon {...props}>
<path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/>
</SvgIcon>
);
Ac... |
src/app/screens/Authentication/screens/Confirmation/index.js | docgecko/react-alt-firebase-starter | /*! React Alt Firebase Starter */
import React from 'react';
import { Route } from 'react-router';
import Confirmation from './components/Confirmation';
export default (
<Route name="verification" path="/verification" handler={Confirmation}/>
);
|
src/components/ContactPage/index.js | KidsFirstProject/KidsFirstProject.github.io | import React from 'react';
import { Container, Col, Row, Media } from 'react-bootstrap';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import {
faSquare,
faEnvelope,
faPhone
} from '@fortawesome/free-solid-svg-icons';
import {
faGithub,
faFacebook,
faTwitter,
faInstagram
} from '@forta... |
app/jsx/choose_mastery_path/components/select-button.js | djbender/canvas-lms | /*
* Copyright (C) 2016 - present Instructure, Inc.
*
* This file is part of Canvas.
*
* Canvas is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3 of the License.
*
* Canvas is distribut... |
src/components/CoreLayout.js | rossta/pathfinder | import React from 'react';
import 'styles/core.scss';
export default class CoreLayout extends React.Component {
static propTypes = {
children : React.PropTypes.element
}
constructor () {
super();
}
render () {
return (
<div className='page-container'>
<div className='view-containe... |
local-cli/templates/HelloNavigation/views/welcome/WelcomeText.ios.js | aljs/react-native | 'use strict';
import React, { Component } from 'react';
import {
StyleSheet,
Text,
View,
} from 'react-native';
export default class WelcomeText extends Component {
render() {
return (
<View style={styles.container}>
<Text style={styles.welcome}>
Welcome to React Native!
</... |
pages/about/index.js | anvilabs/anvilabs.co | /* @flow */
import React from 'react';
import {
ContentContainer,
Main,
PageFooter,
PageHeader,
PageHelmet,
Separator,
StickyNavigation,
TeamList,
} from '../../components';
import team from '../../data/team';
const ContactPage = (): React$Element<any> => (
<Main>
<PageHelmet mixpanelTitle="Abo... |
examples/huge-apps/routes/Course/routes/Grades/components/Grades.js | arusakov/react-router | import React from 'react';
class Grades extends React.Component {
render () {
var assignments = COURSES[this.props.params.courseId].assignments;
return (
<div>
<h3>Grades</h3>
<ul>
{assignments.map(assignment => (
<li key={assignment.id}>{assignment.grade} - {assi... |
docs/app/Examples/collections/Grid/Types/GridExampleDividedVertically.js | ben174/Semantic-UI-React | import React from 'react'
import { Grid, Image } from 'semantic-ui-react'
const GridExampleVerticallyDivided = () => (
<Grid divided='vertically'>
<Grid.Row columns={2}>
<Grid.Column>
<Image src='http://semantic-ui.com/images/wireframe/paragraph.png' />
</Grid.Column>
<Grid.Column>
... |
packages/wix-style-react/src/Button/test/Button.visual.js | wix/wix-style-react | import React from 'react';
import AddChannel from 'wix-ui-icons-common/AddChannel';
import Button from '../Button';
import { SIZES, SKINS } from '../constants';
import { visualize, story, snap } from 'storybook-snapper';
import {
getSkinBackground,
renderButtonBlock,
} from '../../utils/ButtonHelpers';
import Box ... |
client/components/Comment/index.js | abinavseelan/restobook | import React from 'react';
import cn from 'classnames';
import { Link } from 'react-router-dom';
import distanceInWordsToNow from 'date-fns/distance_in_words_to_now';
import Replies from '../Replies';
import styles from './index.scss';
const Comment = ({ username, id, createdAt, text, handleReplyRequest,
replies, n... |
lib/components/global/menu/NavItem.js | fuzz-productions/Mortar-JS | // External Requirements
import React from 'react';
import {Link} from 'react-router';
/**
* NavItem
*
* @type {*|Function}
*/
var NavItem = React.createClass({
propTypes: {
index : React.PropTypes.number,
item : React.PropTypes.shape({
uri : React.PropTypes.string,
text : React.PropType... |
components/Blokk/Blokk.js | NGMarmaduke/bloom | import PropTypes from 'prop-types';
import React from 'react';
import cx from 'classnames';
import css from './Blokk.css';
const Blokk = ({ variant, length, className }) => (
<span
className={ cx(css.root, css[variant], className) }
style={ {
maxWidth: `${length}em`,
} }
/>
);
Blokk.propTypes =... |
src/components/views/NotFound.js | elbstack/elbstack-hackreact-web-3 | import React from 'react'
import { Grid, Row, Col } from 'react-bootstrap'
export default function NotFound() {
return (
<Grid>
<Row>
<Col md={12}>
<h1>Doh! 404!</h1>
<p>These are <em>not</em> the droids you are looking for!</p>
</Col>
</Row>
</Grid>
)
}
|
webpack/move_to_pf/OptionTooltip/index.js | cfouant/katello | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import { Popover, OverlayTrigger } from 'patternfly-react';
import './OptionTooltip.scss';
class OptionTooltip extends Component {
constructor(props) {
super(props);
this.state = {
toolti... |
pages/internship.js | uclaacm/website | import { NextSeo } from 'next-seo';
import Link from 'next/link';
import React from 'react';
import {
Accordion,
AccordionItem,
AccordionItemHeading,
AccordionItemButton,
AccordionItemPanel,
} from 'react-accessible-accordion';
import Banner from '../components/Banner';
import CommitteeInternshipI... |
packages/ndla-icons/src/action/ExpandMore.js | netliferesearch/frontend-packages | /**
* Copyright (c) 2017-present, NDLA.
*
* This source code is licensed under the GPLv3 license found in the
* LICENSE file in the root directory of this source tree.
*
*/
// N.B! AUTOGENERATED FILE. DO NOT EDIT
import React from 'react';
import Icon from '../Icon';
const ExpandMore = props => (
<Icon
vi... |
src/features/preload/index.js | rldona/react-native-tab-view-seed | import React, { Component } from 'react';
import {
View,
Text,
Image,
StyleSheet,
Dimensions,
} from 'react-native';
import * as firebase from 'firebase';
import * as colors from '../../common/colors';
import * as moviesService from '../../services/movies-service';
import * as loginService from '../../ser... |
docs/src/components/Navigation.js | chris-gooley/react-materialize | import React from 'react';
import { NavLink } from 'react-router-dom';
import Collapsible from 'Collapsible';
import CollapsibleItem from 'CollapsibleItem';
import Search from './Search';
import routes from '../routes';
const isMobile = () => ($(window).width() < 993);
const getPageTitle = () => window.location.hash.... |
src/containers/PaymentView/PayPal.js | JamesJin038801/CampID | import React, { Component } from 'react';
import {
Text,
TextInput,
View,
Platform,
TouchableOpacity,
Image,
Alert,
} from 'react-native';
import { connect } from 'react-redux';
import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view';
import Icon from 'react-native-vector-icons/... |
runningdinner-webclient/src/test/TestUtils.js | Clemens85/runningdinner | // test-utils.js
import React from 'react'
import '../shared/i18n/i18n';
import {CONSTANTS as Constants} from "../shared/Constants";
import forEach from 'lodash/forEach';
// re-export everything
//export * from '@testing-library/react';
export function mockAssignableParticipant(participantNr) {
return {
id: par... |
src/test/app/js/i18n/i18nSample.js | cluelessjoe/heroesdesk-front-web | import React from 'react';
import ReactIntl from 'react-intl';
import {langMixin} from '../../lang/langMixin.js';
import {FormattedDate, FormattedNumber, FormattedMessage} from 'react-intl';
export var I18nSample = React.createClass({
mixins: [langMixin],
getMessage : function(){
return ( <FormattedD... |
node_modules/react-bootstrap/es/NavbarCollapse.js | FoxMessenger/nyt-react | import _extends from 'babel-runtime/helpers/extends';
import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from ... |
app/javascript/mastodon/components/dropdown_menu.js | amazedkoumei/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import IconButton from './icon_button';
import Overlay from 'react-overlays/lib/Overlay';
import Motion from '../features/ui/util/optional_motion';
import spring from 'react-motion/lib/spring';
imp... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.