path stringlengths 5 304 | repo_name stringlengths 6 79 | content stringlengths 27 1.05M |
|---|---|---|
src/js/app.js | takuan-osho/react-es2015-skelton | import React from 'react';
import ReactDOM from 'react-dom';
class App extends React.Component {
render() {
return (
<div>Sample App</div>
);
}
}
ReactDOM.render(
<App />,
document.getElementById('app')
);
|
src/input-components/index.js | SteveVitali/react-form-generator | import React from 'react'
export { default as DefaultTextInput } from './DefaultTextInput.jsx'
export { default as VanillaTextInput } from './VanillaTextInput.jsx'
export { default as DefaultBoolInput } from './DefaultBoolInput.jsx'
export { default as DefaultEnumInput } from './DefaultEnumInput.jsx'
export { default ... |
src/svg-icons/hardware/videogame-asset.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwareVideogameAsset = (props) => (
<SvgIcon {...props}>
<path d="M21 6H3c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-10 7H8v3H6v-3H3v-2h3V8h2v3h3v2zm4.5 2c-.83 0-1.5-.67-1.5-1.5s.67-... |
static/src/components/islands/IslandPond.js | andribja/airhornbot | // @flow
// jscs:disable maximumLineLength
import React from 'react';
type Props = {
paused: boolean
};
export default ({paused}: Props): React.Element => (
<svg className={`island pond ${paused ? 'paused' : ''}`} xmlns="http://www.w3.org/2000/svg" width="259" height="251">
<g fill="none" fill-rule="evenodd"... |
src/svg-icons/social/party-mode.js | barakmitz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialPartyMode = (props) => (
<SvgIcon {...props}>
<path d="M20 4h-3.17L15 2H9L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 3c1.63 0 3.06.79 3.98 2H12c-1.66 0-3 1.34-3 3 0 .... |
test/containers/CounterPage.spec.js | daskinnyman/electron-QA | import React from 'react';
import { mount } from 'enzyme';
import { Provider } from 'react-redux';
import { createBrowserHistory } from 'history';
import { ConnectedRouter } from 'react-router-redux';
import CounterPage from '../../app/containers/CounterPage';
import { configureStore } from '../../app/store/configureSt... |
src/components/post/Post.js | jaggerwang/zqc-admin-demo | /**
* 在球场
* zaiqiuchang.com
*/
import React from 'react'
import {MdPerson, MdLocationOn, MdPlayCircleOutline} from 'react-icons/lib/md'
import * as helpers from '../../helpers'
export default props => {
let {post} = props
return (
<div className='post-item bg-white' style={styles.post}>
<div classN... |
assets/javascript/components/viewActivity/activityLinksList.js | colinjeanne/learning-site | import ActivityLink from './activityLink';
import { activityLinksPropType } from './../propTypes';
import React from 'react';
const activityLinksList = props => {
const sorted = [...props.activityLinks].sort((a, b) => {
if (a.title < b.title) {
return -1;
} else if (a.title > b.title) {... |
pages/about.js | kevinsproles/react-static-test | /**
* React Static Boilerplate
* https://github.com/koistya/react-static-boilerplate
* Copyright (c) Konstantin Tarkus (@koistya) | MIT license
*/
import React, { Component } from 'react';
export default class extends Component {
render() {
return (
<div>
<h1>About Us</h1>
<p>Coming s... |
app/components/Parser.js | sdlfj/eq-roll-tracker | // @flow
import React, { Component } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import * as ParserActions from '../actions/parser';
import styles from './Parser.css';
import RollList from './RollList';
import type { rollType } from '../reducers/parser';
import sound... |
files/hyphenator/4.3.0/patterns/en-gb.js | Sneezry/jsdelivr | // The en-GB hyphenation patterns are retrieved from
// http://tug_org/svn/texhyphen/trunk/collaboration/repository/hyphenator/
/*global Hyphenator*/
Hyphenator.languages['en-gb'] = {
leftmin: 2,
rightmin: 3,
specialChars: "",
patterns: {
3: "sw2s2ym1p2chck1cl2cn2st24sss1rzz21moc1qcr2m5q2ct2byb1... |
src/components/Stuff.js | zhoutk/material-admin | /**
* Created by zhoutk on 17-4-18.
*/
import React, { Component } from 'react';
// import styled from 'styled-components';
import './Home.css';
class Stuff extends Component {
render() {
return (
<div>
<h2>STUFF</h2>
<p>Mauris sem velit, vehicula eget sodales... |
src/isomorphic/containers/App/index.js | hzhu/react-universal | import React from 'react'
import { connect } from 'react-redux'
import { Route } from 'react-router-dom'
import { ConnectedRouter,
push } from 'react-router-redux'
import history from '../../store/history'
import { isServer } from '../../utils'
import Home from '../../components/Home'
import Topics from '../... |
src/svg-icons/hardware/mouse.js | manchesergit/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwareMouse = (props) => (
<SvgIcon {...props}>
<path d="M13 1.07V9h7c0-4.08-3.05-7.44-7-7.93zM4 15c0 4.42 3.58 8 8 8s8-3.58 8-8v-4H4v4zm7-13.93C7.05 1.56 4 4.92 4 9h7V1.07z"/>
</SvgIcon>
);
HardwareMouse =... |
examples/huge-apps/routes/Grades/components/Grades.js | rubengrill/react-router | import React from 'react'
class Grades extends React.Component {
render() {
return (
<div>
<h2>Grades</h2>
</div>
)
}
}
export default Grades
|
src/svg-icons/av/skip-next.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let AvSkipNext = (props) => (
<SvgIcon {...props}>
<path d="M6 18l8.5-6L6 6v12zM16 6v12h2V6h-2z"/>
</SvgIcon>
);
AvSkipNext = pure(AvSkipNext);
AvSkipNext.displayName = 'AvSkipNext';
AvSkipNext.muiName = 'SvgIcon... |
nlyyAPP/component/药物管理/查询药物号/MLCxywhSR.js | a497500306/nlyy_APP | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View,
TouchableOpacity,
Navigator,
TextInput,
ActivityIndicator,
Alert
} from 'react-native';
var Dimensions = r... |
node_modules/systemjs-builder/node_modules/traceur/src/runtime/polyfills/Promise.js | UrbanRiskSlumRedevelopment/Maya | // Copyright 2013 Traceur Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed ... |
fixtures/packaging/systemjs-builder/prod/input.js | kaushik94/react | import React from 'react';
import ReactDOM from 'react-dom';
ReactDOM.render(
React.createElement('h1', null, 'Hello World!'),
document.getElementById('container')
);
|
src1/utils/index.js | Cron-J/CSV-REE | import React from 'react';
import { DevTools, DebugPanel, LogMonitor } from 'redux-devtools/lib/react';
export function createConstants (...constants) {
return constants.reduce((acc, constant) => {
acc[constant] = constant;
return acc;
}, {});
}
export function createReducer (initialState, reducerMap) {
... |
_v1/quiz/QuizForm.js | ETBlue/llscanner | import React, { Component } from 'react'
import './QuizForm.css'
class QuizForm extends Component {
render () {
const id = this.props.id
const title = this.props.title
const description = this.props.description
const type = this.props.type
const changeInput = this.props.changeInput
const se... |
app/EditCard.js | nikpetrovic/KanbanApp | import React, { Component } from 'react';
import CardForm from './CardForm';
class EditCard extends Component {
componentWillMount() {
let card = this.props.cards.find((card) => card.id == this.props.params.card_id);
this.setState(...card);
}
handleChange(field, value) {
this.setState({[field]: value})... |
ajax/libs/react-native-web/0.0.0-b096cd2d/modules/UnimplementedView/index.js | cdnjs/cdnjs | function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; _setPrototypeOf(subClass, superClass); }
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; ret... |
src/utils.js | Kilix/selectless | import React from 'react'
import findDOMNode from 'react-dom/lib/findDOMNode'
import controller from './controller'
export function renderOrCloneComponent(BaseComponent, props, children) {
if (React.isValidElement(BaseComponent)) {
return React.cloneElement(BaseComponent, props, children)
}
return React.cre... |
src/components/Counter/Counter.js | 38Slava/redux-webrtc | import React from 'react'
import classes from './Counter.scss'
export const Counter = (props) => (
<div>
<h2 className={classes.counterContainer}>
Counter:
{' '}
<span className={classes['counter--green']}>
{props.counter}
</span>
</h2>
<button className='btn btn-default' ... |
node_modules/react-router/es6/Link.js | yeshdev1/Everydays-project | var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
function _objectWithoutProperties(obj, keys) { var target = {... |
stories/sorting/sorting.stories.js | Edgesyntax/tableComponent | import React from 'react';
import { storiesOf } from '@storybook/react';
import { withReadme } from 'storybook-readme';
// Stories
import Main from "../main.jsx";
// Readme
import SortingSortableReadme from "./sorting-sortable.md";
import SortingDefaultSortReadme from "./sorting-default-sort.md";
import SortingCustom... |
examples/src/index.js | jakezatecky/react-checkbox-tree | import React from 'react';
import ReactDOM from 'react-dom';
import BasicExample from './js/BasicExample';
import CustomIconsExample from './js/CustomIconsExample';
import ClickableLabelsExample from './js/ClickableLabelsExample';
import DisabledExample from './js/DisabledExample';
import ExpandAllExample from './js/E... |
ajax/libs/cyclejs-dom/3.2.1/cycle-dom.js | calebmer/cdnjs | (function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.CycleDOM = f()... |
ajax/libs/material-ui/5.0.0-alpha.32/RadioGroup/RadioGroup.min.js | cdnjs/cdnjs | import _extends from"@babel/runtime/helpers/esm/extends";import _objectWithoutPropertiesLoose from"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";import*as React from"react";import PropTypes from"prop-types";import FormGroup from"../FormGroup";import useForkRef from"../utils/useForkRef";import useControlled f... |
phoenix-tracing-webapp/src/main/webapp/js/lib/jquery.min.js | Guavus/phoenix | /*! jQuery v1.11.3 | (c) 2005, 2015 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof wind... |
packages/material-ui-icons/src/SlideshowOutlined.js | kybarg/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<path d="M10 8v8l5-4-5-4zm9-5H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z" />
, 'SlideshowOutlined');
|
src/__tests__/fileMocks/esClassNamed/Bold.js | react-cosmos/fs-playground | // @flow
import React, { Component } from 'react';
export default class Bold extends Component<{ name: string }> {
render() {
return <strong>{this.props.name}</strong>;
}
}
|
test/ListGroupItemSpec.js | JimiHFord/react-bootstrap | import React from 'react';
import ReactTestUtils from 'react/lib/ReactTestUtils';
import ListGroupItem from '../src/ListGroupItem';
describe('ListGroupItem', function () {
it('Should output a "span" with the class "list-group-item"', function () {
let instance = ReactTestUtils.renderIntoDocument(
<ListGro... |
JS Web/ReactJS/Final Project/zoo-market/src/components/common/NotFoundPage.js | mitaka00/SoftUni | import React from 'react';
const NotFoundPage = () => (
<h1 id='notFound'>This page is not found</h1>
)
export default NotFoundPage |
docs/app/Examples/modules/Dimmer/States/DimmerExampleActive.js | ben174/Semantic-UI-React | import React from 'react'
import { Dimmer, Segment } from 'semantic-ui-react'
const DimmerExampleActive = () => (
<Segment>
<Dimmer active />
<p>
<img src='http://semantic-ui.com/images/wireframe/short-paragraph.png' />
</p>
<p>
<img src='http://semantic-ui.com/images/wireframe/short-par... |
lib/doc/js/jquery-1.4.2.min.js | rsantellan/symfony2-maith-roundcube | /*!
* jQuery JavaScript Library v1.4.2
* http://jquery.com/
*
* Copyright 2010, John Resig
* Dual licensed under the MIT or GPL Version 2 licenses.
* http://jquery.org/license
*
* Includes Sizzle.js
* http://sizzlejs.com/
* Copyright 2010, The Dojo Foundation
* Released under the MIT, BSD, and GPL Licenses.
... |
assets/js/android_3p-bundle.js | terrytowne/android-developer-cn | //third_party/javascript/google_code_prettify/src/prettify.js
/**
* @license Copyright (C) 2006 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.o... |
examples/with-freactal/components/app.js | giacomorebonato/next.js | import React from 'react'
import { fetchUserRepos } from '../githubApi'
import provideStateFactory from '../provideState'
export default (Page) => {
const App = ({ serverState }) => {
const withState = provideStateFactory(serverState)
const PageWithState = withState(Page)
return <PageWithState />
}
... |
ajax/libs/rxjs/2.3.23/rx.lite.extras.js | zhangbg/cdnjs | // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information.
;(function (factory) {
var objectTypes = {
'boolean': false,
'function': true,
'object': true,
'number': false,
'string': false,
... |
node_modules/react/lib/KeyEscapeUtils.js | mohammed52/something.pk | /**
* Copyright 2013-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*
*/
'use st... |
ajax/libs/flocks.js/0.15.3/flocks.min.js | zhangbg/cdnjs | if("undefined"===typeof k)var k=require("react"); (function(){function q(){return!0}function r(){return!0}function b(a,b){if("string"===typeof a)if(~"warn debug error log info exception assert".split(" ").indexOf(a,0))console[a]("Flocks2 ["+a+"] "+b.toString());else console.log("Flocks2 [Unknown level] "+b.toString());... |
__tests__/src/components/header.spec.js | bluedaniel/Kakapo-app | import React from 'react';
import Enzyme, { shallow } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
import renderer from 'react-test-renderer';
import { Header } from 'components/';
import { getData } from '../helper';
Enzyme.configure({ adapter: new Adapter() });
function setup(props = {}) {
const ... |
packages/wix-style-react/src/StarsRatingBar/components/InteractiveModeStar.js | wix/wix-style-react | import React from 'react';
import PropTypes from 'prop-types';
import { withFocusable } from 'wix-ui-core/dist/src/hocs/Focusable/FocusableHOC';
import { st, classes } from './InteractiveModeStar.st.css';
import { dataHooks, starRatingBarSizesInPx } from '../constants';
import StarFilledIcon from 'wix-ui-icons-common... |
src/svg-icons/maps/directions-bus.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsDirectionsBus = (props) => (
<SvgIcon {...props}>
<path d="M4 16c0 .88.39 1.67 1 2.22V20c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h8v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1.78c.61-.55 1-1.34 1-2.22V6c0-3.5-3.58-4-8... |
src/parser/priest/shared/modules/features/DesperatePrayer.js | FaideWW/WoWAnalyzer | import React from 'react';
import StatisticBox from 'interface/others/StatisticBox';
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 SpellUsable... |
app/containers/NotFoundPage/index.js | qiubit/lamp-experiment | /**
* NotFoundPage
*
* This is the page we show when the user visits a url that doesn't have a route
*/
import React from 'react';
import messages from './messages';
import { FormattedMessage } from 'react-intl';
import H1 from 'components/H1';
export default function NotFound() {
return (
<article>
... |
MenuItem/MenuItem.js | dhavalbyteprophecy/material-ui-build | 'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _extends2 = require('babel-runtime/helpers/extends');
var _extends3 = _interopRequireDefault(_extends2);
var _objectWithoutProperties2 = require('babel-runtime/helpers/objectWithoutProperties');
var _objectWithoutProperties3 = _inte... |
MediaBrowser.WebDashboard/dashboard-ui/bower_components/Sortable/react-sortable-mixin.js | ChubbyArse/Emby | /**
* @author RubaXa <trash@rubaxa.org>
* @licence MIT
*/
(function (factory) {
'use strict';
if (typeof module != 'undefined' && typeof module.exports != 'undefined') {
module.exports = factory(require('./Sortable'));
}
else if (typeof define === 'function' && define.amd) {
define(['./Sortable'], factory)... |
ajax/libs/es6-shim/0.28.1/es6-shim.js | emmy41124/cdnjs | /*!
* https://github.com/paulmillr/es6-shim
* @license es6-shim Copyright 2013-2015 by Paul Miller (http://paulmillr.com)
* and contributors, MIT License
* es6-shim: v0.27.1
* see https://github.com/paulmillr/es6-shim/blob/0.27.1/LICENSE
* Details and documentation:
* https://github.com/paulmillr/es6-... |
Docker/KlusterKiteMonitoring/klusterkite-web/src/components/Form/RowBlock.js | KlusterKite/KlusterKite | import React from 'react';
import { Row } from 'formsy-react-components';
import './styles.css';
export default class RowBlock extends React.Component { // eslint-disable-line react/prefer-stateless-function
static propTypes = {
label: React.PropTypes.string.isRequired,
};
render() {
return (
<Ro... |
theme/src/components/homeSlider.js | cezerin/cezerin | import React from 'react';
import PropTypes from 'prop-types';
import { NavLink } from 'react-router-dom';
import ImageGallery from 'react-image-gallery';
import { themeSettings } from '../lib/settings';
const renderItem = item => (
<div className="image-gallery-image">
<NavLink to={item.path || ''}>
<img src={i... |
plugins/editors/tinymce/jscripts/tiny_mce/plugins/devkit/editor_plugin.js | healthcommcore/lamps | tinyMCE.importPluginLanguagePack('devkit');var TinyMCE_DevKitPlugin={_logFilter:'\\[(importCSS|execCommand|execInstanceCommand|debug)\\]',_logPadding:'',_startTime:null,_benchMark:false,_winLoaded:false,_isDebugEvents:false,getInfo:function(){return{longname:'Development Kit',author:'Moxiecode Systems AB',authorurl:'ht... |
src/layouts/CoreLayout/CoreLayout.js | crackHu/react-kit | import React from 'react'
import Header from '../../components/Header'
import './CoreLayout.scss'
import '../../styles/core.scss'
export const CoreLayout = ({ children }) => (
<div className='container text-center'>
<Header />
<div className='core-layout__viewport'>
{children}
</div>
</div>
)
Co... |
ajax/libs/jssip/0.7.11/jssip.js | dada0423/cdnjs | /*
* JsSIP v0.7.11
* the Javascript SIP library
* Copyright: 2012-2015 José Luis Millán <jmillan@aliax.net> (https://github.com/jmillan)
* Homepage: http://jssip.net
* License: MIT
*/
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&de... |
src/route/profit/WithdrawLog.js | simors/yjbAdmin | /**
* Created by yangyang on 2017/11/7.
*/
import React from 'react'
import {connect} from 'react-redux'
import { Row, Col, DatePicker, Form, Table, Button, message } from 'antd'
import {profitSelector, profitAction} from './redux'
import moment from "moment"
import {WITHDRAW_STATUS, orderSelector} from '../order'
c... |
ajax/libs/onsen/2.0.0-rc.15/js/angular-onsenui.min.js | him2him2/cdnjs | /*! angular-onsenui.js for onsenui - v2.0.0-rc.15 - 2016-06-29 */
!function(){var initializing=!1,fnTest=/xyz/.test(function(){xyz})?/\b_super\b/:/.*/;this.Class=function(){},Class.extend=function(prop){function Class(){!initializing&&this.init&&this.init.apply(this,arguments)}var _super=this.prototype;initializing=!0;... |
src/renderers/dom/ReactDOMClient.js | gajus/react | /**
* Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
* @providesModule ... |
app/containers/AboutPage/TheToolbox.js | BeautifulTrouble/beautifulrising-client | /**
*
* AboutPageComponents
*
*/
import React from 'react';
import styled from 'styled-components';
import Markdown from 'react-remarkable';
import ContentBlock from 'components/ContentBlock';
import LanguageThemeProvider from 'components/LanguageThemeProvider';
import ToolTypeAllFull from 'containers/ToolTypeAllFull'... |
app/example/components/ExampleItem.js | clariussystems/react-orderable | import classNames from 'classnames';
import ImmutablePropTypes from 'react-immutable-proptypes';
import React from 'react';
import styles from './ExampleItem.scss';
class ExampleItem extends React.Component {
static propTypes = {
className: React.PropTypes.string,
dragging: React.PropTypes.bool,
ghost: ... |
packages/react/src/components/MultiSelect/__tests__/MultiSelect-test.e2e.js | carbon-design-system/carbon-components | /**
* Copyright IBM Corp. 2016, 2018
*
* This source code is licensed under the Apache-2.0 license found in the
* LICENSE file in the root directory of this source tree.
*/
import 'carbon-components/scss/components/multi-select/_multi-select.scss';
import React from 'react';
import { mount } from '@cypress/react... |
src/containers/App/index.js | IDEOorg/steps-guide-builder | import React from 'react';
import PropTypes from 'prop-types';
import './index.less';
import Header from '../../components/Header';
import config from '../../data/config';
import { connect } from 'react-redux';
const App = (props) => {
window.scrollTo(0, 0);
return (
<div className="app">
<Header feedbac... |
src/routes/Counter/components/Counter.js | billdevcode/spaceship-emporium | import React from 'react'
import PropTypes from 'prop-types'
export const Counter = ({ counter, increment, doubleAsync }) => (
<div style={{ margin: '0 auto' }} >
<h2>Counter: {counter}</h2>
<button className='btn btn-primary' onClick={increment}>
Increment
</button>
{' '}
<button className... |
src/index.js | crhain/freeCodeCamp-Simon | import React from 'react';
import ReactDOM from 'react-dom';
import App from 'App';
import 'index.css';
ReactDOM.render(
<App />,
document.getElementById('root')
);
|
ajax/libs/clappr/0.0.46/clappr.js | bootcdn/cdnjs | require=(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o]... |
admin/client/App/components/Navigation/Mobile/SectionItem.js | pr1ntr/keystone | /**
* A mobile section
*/
import React from 'react';
import MobileListItem from './ListItem';
import { Link } from 'react-router';
const MobileSectionItem = React.createClass({
displayName: 'MobileSectionItem',
propTypes: {
children: React.PropTypes.node.isRequired,
className: React.PropTypes.string,
curren... |
client/trello/src/app/components/BoardOptionsItems/BoardOptionsItems.js | Madmous/madClones | import React from 'react';
import { BoardOptionsItem } from '../index';
import './BoardOptionsItems.css';
export default function BoardOptionsItems() {
const renderBoardOptionsItemList = () => {
return (
<ul className="BoardOptions-List">
<BoardOptionsItem boardName="Boards" iconName="columns"/>
... |
client/components/FlassCommon/Video/VideoVolumeBar/VideoVolumeContainer/VideoVolumeContainerComponent.js | Nexters/flass | import React, { Component } from 'react';
import PropTypes from 'prop-types';
const { arrayOf, element } = PropTypes;
const propTypes = {
children: element.isRequired
};
const defaultProps = {};
class VideoVolumeContainerComponent extends Component {
render() {
const { children } = this.props;
return (
... |
examples/huge-apps/routes/Course/components/Dashboard.js | mozillo/react-router | import React from 'react'
class Dashboard extends React.Component {
render() {
return (
<div>
<h3>Course Dashboard</h3>
</div>
)
}
}
export default Dashboard
|
packages/react-dom/src/events/getListener.js | chicoxyzzy/react | /**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
* @flow
*/
import type {Fiber} from 'react-reconciler/src/ReactInternalTypes';
import type {Props} from '../client/ReactDOMHostConfi... |
src/auth/RequireLogin.js | ryanbaer/busy | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { getIsAuthFetching, getIsAuthenticated } from '../reducers';
import Loading from '../components/Icon/Loading';
import Error401 from '../statics/Error401';
const RequiredLogin = ({ children, authenticated, fetc... |
ajax/libs/ember-data.js/1.0.0-beta.2/ember-data.prod.js | cloudrifles/cdnjs | (function() {
var define, requireModule;
(function() {
var registry = {}, seen = {};
define = function(name, deps, callback) {
registry[name] = { deps: deps, callback: callback };
};
requireModule = function(name) {
if (seen[name]) { return seen[name]; }
seen[name] = {};
var mod, deps, callb... |
tests/react_native_tests/test_data/native_code/SVGComponent/app/components/UserConnect/component.js | ibhubs/sketch-components | /**
* @flow
*/
import React from 'react'
import PropTypes from 'prop-types'
import { observer } from 'mobx-react/native'
import styles from './styles'
import Button from '@rn/commons/app/components/VIButton/VIButton'
import NameStyledComponent from '../NameStyledComponent'
import styled from 'styled-components/nativ... |
ajax/libs/angular-google-maps/2.1.0-X.8/angular-google-maps.js | kristoferjoseph/cdnjs | /*! angular-google-maps 2.1.0-X.8 2015-03-28
* AngularJS directives for Google Maps
* git: https://github.com/angular-ui/angular-google-maps.git
*/
;
(function( window, angular, undefined ){
'use strict';
/*
!
The MIT License
Copyright (c) 2010-2013 Google, Inc. http://angularjs.org
Permission is hereby grante... |
src/components/Account/EditIndex.js | iamraphson/mernmap | /**
* Created by Raphson on 9/26/16.
*/
import React from 'react';
import { Link, hashHistory } from 'react-router';
import MyInput from '../forms/Input';
import MySelect from '../forms/Select';
import Formsy from 'formsy-react';
import MyTextarea from '../forms/Textarea';
import NavBar from '../NavBar/index';
import... |
src/GodNamesLoadingFetch.js | Visovsiouk/smite-random-picker | import React from 'react';
import { Col } from 'react-bootstrap';
function shuffleArray(names, src, selsrc) {
let i = names.length - 1;
for (; i > 0; i--) {
const j = Math.floor(Math.random() * (i + 1));
const tempname = names[i];
names[i] = names[j];
names[j] = tempname;
const tempsrc = src[i];
src[i] =... |
nailgun/static/views/cluster_page_tabs/nodes_tab_screens/add_nodes_screen.js | huntxu/fuel-web | /*
* Copyright 2014 Mirantis, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may
* not use this file except in compliance with the License. You may obtain
* a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed ... |
client/redux/rootReducer.js | sylvainlap/strapi-frontend | import { combineReducers } from 'redux';
import { routerReducer as routing } from 'react-router-redux';
import auth from './modules/auth';
import errorMessage from './modules/errorMessage';
import messages from './modules/messages';
export default combineReducers({
messages,
auth,
errorMessage,
routing,
});
|
src/form.spec.js | Inkdpixels/react-ux-forms | import test from 'ava';
import React from 'react';
import {shallow} from 'enzyme';
import sinon from 'sinon';
import Form from './form';
import Section from './section';
import Item from './item';
const Component = props => <div {...props}/>;
const Input = props => <input type="text" {...props}/>;
const Button = props... |
src/routes/Player/views/PlayerView.js | bhj/karaoke-forever | import React from 'react'
import { useSelector, useStore } from 'react-redux'
import { injectReducer } from 'store/reducers'
import playerReducer from '../modules/player'
import playerVisualizerReducer from '../modules/playerVisualizer'
import PlayerController from '../components/PlayerController'
import screenfull fr... |
app/src/MoveInfo.js | struz/smash-move-viewer | import React, { Component } from 'react';
import ReactTooltip from 'react-tooltip';
import './Move.css';
import './MoveInfo.css';
export const hitboxIdColors = [
'#E6194B',
'#3CB44B',
'#000080',
'#0082C8',
'#F58231',
'#911EB4',
'#46F0F0',
'#D2F53C',
'#008080',
'#AA6E28'
]
// Hitbox types, matches... |
lib/helpers/uuid.js | edcast-inc/react-menu | var count = 0;
module.exports = function () {
return 'react-menu-' + count++;
};
|
src/components/ContentSwitcher/ContentSwitcher.stories.js | wfp/ui | import React from 'react';
import ContentSwitcher from './ContentSwitcher';
import markdown from './README.mdx';
import Switch from '../Switch';
import { iconAddGlyph } from '@wfp/icons';
import Icon from '../Icon';
export default {
title: 'Components/Content Related/ContentSwitcher',
component: ContentSwitcher,
... |
test/integration/custom-error/pages/_error.js | zeit/next.js | import React from 'react'
class Error extends React.Component {
static getInitialProps({ res, err }) {
const statusCode = res ? res.statusCode : err ? err.statusCode : null
return { statusCode }
}
render() {
return (
<>
<h3>Custom error!!</h3>
<p>
{this.props.statusCo... |
zt/bri_jq/js/jquery-1.8.3.min.js | linmingling/demo | /*! jQuery v1.8.3 jquery.com | jquery.org/license */
(function(e,t){function _(e){var t=M[e]={};return v.each(e.split(y),function(e,n){t[n]=!0}),t}function H(e,n,r){if(r===t&&e.nodeType===1){var i="data-"+n.replace(P,"-$1").toLowerCase();r=e.getAttribute(i);if(typeof r=="string"){try{r=r==="true"?!0:r==="false"?!1:r===... |
packages/material-ui-icons/src/StayCurrentPortrait.js | kybarg/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<path d="M17 1.01L7 1c-1.1 0-1.99.9-1.99 2v18c0 1.1.89 2 1.99 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z" />
, 'StayCurrentPortrait');
|
client/modules/App/components/Footer/Footer.js | williaumwu/mern-sample | import React from 'react';
// Import Style
import styles from './Footer.css';
export function Footer() {
return (
<div style={{ background: '#333c5a' }} className={styles.footer}>
<p>© 2016 · MagicBlog · Magic Leap Exam</p>
</div>
);
}
export default Footer;
|
draft-js-drag-n-drop-upload-plugin/src/components/UploadPlaceholder.js | dagopert/draft-js-plugins | import React, { Component } from 'react';
class UploadPlaceholder extends Component {
render() {
const { blockProps, block } = this.props;
return (
<span contentEditable={false} data-offset-key={`${block.get('key')}-0-0`}>
![Uploading {blockProps.name}...](){' '}
</span>
);
}
}
ex... |
packages/material-ui-icons/src/LeakRemoveTwoTone.js | Kagami/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<React.Fragment><path fill="none" d="M0 0h24v24H0V0z" /><g><path d="M14 3h-2c0 1.35-.31 2.63-.84 3.77l1.49 1.49C13.51 6.7 14 4.91 14 3zM21 12v-2c-1.91 0-3.7.49-5.27 1.35l1.49 1.49c1.15-.53 2.43-.84 3.78-.84zM2... |
test/index.js | Ericat/component-beta-bar | import 'babel-polyfill';
import BetaBar from '../src';
import React from 'react';
import chai from 'chai';
import spies from 'chai-spies';
import BarWrapper from '@economist/component-bar-wrapper';
chai.should();
chai.use(spies);
describe('BetaBar component', () => {
/* eslint-disable init-declarations */
let rea... |
src/Provider.js | gribnoysup/react-yandex-maps | /* global __DOCZ__ */
import React from 'react';
import PropTypes from 'prop-types';
import { YMapsContext } from './Context';
import { YMaps } from './YMaps';
export default class Provider extends React.Component {
constructor(props) {
super(props);
this.ymaps = new YMaps(props);
}
componentDidMount()... |
techCurriculum/ui/solutions/5.1/src/components/Card.js | AnxChow/EngineeringEssentials-group | /**
* Copyright 2017 Goldman Sachs.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... |
webpack/components/AnsibleRolesSwitcher/components/AnsibleRolesSwitcherError.js | theforeman/foreman_ansible | import React from 'react';
import { Col, Alert } from 'patternfly-react';
import PropTypes from 'prop-types';
const ErrorMsg = ({ error }) => {
const status = error.statusText ? `${error.statusText}: ` : '';
return `${status}${error.errorMsg}`;
};
const AnsibleRolesSwitcherError = ({ error }) =>
error && error.... |
static/Brython3.1.1-20150328-091302/Lib/jqueryui/jquery-1.11.2.min.js | 2014c2g5/Number1 | /*! jQuery v1.11.2 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof wind... |
src/components/withViewport.js | lolilukia/smda | /**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-2016 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, { Component } from 'react'; // eslint-disabl... |
ios_ReactSideMenu/index.android.js | mitrais-cdc-mobile/react-pocs | /**
* Sample React Native App
* https://github.com/facebook/react-native
*/
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View
} from 'react-native';
class POC extends Component {
render() {
return (
<View style={styles.container}>
<Text style={styles... |
__tests__/js/scenes/Home.js | arcturus/journey | import createStore from '../../../js/store/create-store';
import Home from '../../../js/scenes/Home';
import renderer from 'react-test-renderer';
import React from 'react';
import 'react-native';
jest.mock('../../../js/components/Header', () => 'Header');
it('renders correctly', () => {
renderer.create(
<Home s... |
app/javascript/mastodon/features/account_timeline/index.js | NS-Kazuki/mastodon | import React from 'react';
import { connect } from 'react-redux';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { fetchAccount } from '../../actions/accounts';
import { expandAccountFeaturedTimeline, expandAccountTimeline } from '../../actions/timelines';
import ... |
ajax/libs/reactable/0.9.7/reactable.js | AlexisArce/cdnjs | /** @jsx React.DOM */
"use strict";
(function (root, factory) {
if (typeof define === 'function' && define.amd) { // AMD. Register as an anonymous module.
define(['react'], factory);
} else if (typeof exports === 'object') {
// Node. Does not work with strict CommonJS, but
// only Commo... |
application/bower_components/datatables/media/js/jquery.js | urandu/muli-health | /*! jQuery v1.11.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof wind... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.