How to use the isomorphic-style-loader/withStyles function in isomorphic-style-loader

To help you get started, we’ve selected a few isomorphic-style-loader examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github elmadev / elmaonline-site / src / pages / home / Home.js View on Github external
? 'Loading...'
                    : getReplays.map(i => (
                        
                      ))}
                
              
            
          
        
      
    );
  }
}

export default compose(
  withStyles(s),
  graphql(homeQuery),
)(Home); // place the query object in the graphql decorator here so it's available in the this.props object
github elmadev / elmaonline-site / src / routes / register / Register.js View on Github external
title: PropTypes.string.isRequired,
  };

  render() {
    return (
      <div>
        <div>
          <h1>{this.props.title}</h1>
          <p>...</p>
        </div>
      </div>
    );
  }
}

export default withStyles(s)(Register);
github elmadev / elmaonline-site / src / routes / login / Login.js View on Github external
/&gt;
              
            
            <div>
              <button type="submit">
                Log in
              </button>
            </div>
          
        
      
    );
  }
}

export default withStyles(s)(Login);
github elmadev / elmaonline-site / src / pages / levelpack / LevelPack.js View on Github external
}}
                /&gt;
              )}
            
          );
        }}
      
    
  );
};

LevelPack.propTypes = {
  name: PropTypes.string.isRequired,
};

export default withStyles(s)(LevelPack);
github elmadev / elmaonline-site / src / pages / level / Level.js View on Github external
<time>
              </time>
            
          ))}
      
    
  
));

TimeTable.propTypes = {
  data: PropTypes.arrayOf(PropTypes.shape()),
};

const AllTimes = compose(
  withStyles(s),
  graphql(allTimesQuery, {
    options: ownProps =&gt; ({
      variables: {
        LevelIndex: ownProps.LevelIndex,
      },
    }),
  }),
)(props =&gt; {
  const {
    data: { getTimes, loading },
  } = props;
  return loading ?  : ;
});

class Level extends React.Component {
  constructor(props) {
github elmadev / elmaonline-site / src / pages / kuskis / Kuskis.js View on Github external
})}
        
      
    );
  }
}

Kuskis.propTypes = {
  data: PropTypes.shape({
    loading: PropTypes.bool.isRequired,
    getKuskis: PropTypes.array,
  }).isRequired,
};

export default compose(
  withStyles(s),
  graphql(kuskiQuery),
)(Kuskis);
github elmadev / elmaonline-site / src / pages / battles / Battles.js View on Github external
&lt;
          
          <span>
            {start.format('ddd DD.MM.YYYY')}
          </span>
          <button type="button">
            &gt;
          </button>
        
        
      
    );
  }
}

export default withStyles(s)(Battles);
github elmadev / elmaonline-site / src / components / Login / Login.js View on Github external
variant="contained"
                    color="primary"
                  &gt;
                    Login
                  
                
              
            )}
          
        )}
      
    );
  }
}

export default withStyles(s)(Login);
github elmadev / elmaonline-site / src / components / Loading / Loading.js View on Github external
import React from 'react';
import withStyles from 'isomorphic-style-loader/withStyles';
import s from './loading.css';

const Loading = () =&gt; (
  <div>
    <div>
      <div>
      <div>
      <div>
    </div>
  </div>
);

export default withStyles(s)(Loading);
</div></div></div>
github elmadev / elmaonline-site / src / components / SideBar / SideBar.js View on Github external
Editor
            
          
        
      
    );
  }
}

const mapStateToProps = state =&gt; {
  const { sidebarVisible } = state.ui;
  return { sidebarVisible };
};

export default withStyles(s)(
  connect(
    mapStateToProps,
    { toggleSidebar },
  )(SideBar),
);

isomorphic-style-loader

CSS style loader for Webpack optimized for critical path CSS rendering and isomoprhic web apps

MIT
Latest version published 18 days ago

Package Health Score

87 / 100
Full package analysis