Tweaking style a bit

This commit is contained in:
Timothy Warren 2017-04-05 16:53:24 -04:00
parent f8d181d01b
commit cc1ca7f645
4 changed files with 5 additions and 25 deletions

View File

@ -23,7 +23,7 @@
"react/sort-comp": ["error", { "react/sort-comp": ["error", {
"order": ["type-annotations", "static-methods", "lifecycle", "everything-else", "render"] "order": ["type-annotations", "static-methods", "lifecycle", "everything-else", "render"]
}], }],
"react/jsx-no-bind": "off", "react/prop-types": "off",
"react/jsx-filename-extension": ["error", { "extensions": [".js", ".jsx"] }], "react/jsx-filename-extension": ["error", { "extensions": [".js", ".jsx"] }],
"react/prefer-stateless-function": "off" "react/prefer-stateless-function": "off"
}, },

View File

@ -1,20 +1,9 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html lang="en-us">
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>Hello Electron React!</title> <title>Hello Electron React!</title>
<link rel="stylesheet" href="./css/photon.min.css" /> <link rel="stylesheet" href="./css/photon.min.css" />
<script>
(() => {
if (!process.env.HOT) {
const link = document.createElement('link');
link.rel = 'stylesheet';
link.href = './dist/style.css';
// HACK: Writing the script path should be done with webpack
document.getElementsByTagName('head')[0].appendChild(link);
}
})();
</script>
</head> </head>
<body> <body>
<div id="root"></div> <div id="root"></div>

View File

@ -1,16 +1,12 @@
import React, { Component } from 'react'; import React, { Component } from 'react';
// import { Link } from 'react-router';
import styles from './Home.css';
export default class Home extends Component { export default class Home extends Component {
render() { render() {
return ( return (
<div> <div>
<div className={styles.container} data-tid="container">
<h1>Home</h1> <h1>Home</h1>
<h3>...is where the heart is</h3> <h3>...is where the heart is</h3>
</div> </div>
</div>
); );
} }
} }

View File

@ -3,12 +3,7 @@ import { Provider } from 'react-redux';
import { Router } from 'react-router'; import { Router } from 'react-router';
import routes from '../routes'; import routes from '../routes';
type RootType = { export default function Root({ store, history }) {
store: {},
history: {}
};
export default function Root({ store, history }: RootType) {
return ( return (
<Provider store={store}> <Provider store={store}>
<Router key={Math.random()} history={history} routes={routes} /> <Router key={Math.random()} history={history} routes={routes} />