Browse Source

fixing code style

master
Yutsuo 6 years ago
parent
commit
9a47e2483e
  1. 8
      03/docker-compose.yml
  2. 7088
      03/package-lock.json
  3. 46
      03/package.json
  4. 22
      03/public/index.html
  5. 4
      03/src/App.js
  6. 6
      03/src/index.css

8
03/docker-compose.yml

@ -1,4 +1,4 @@
version: "3.7"
version: '3.7'
services:
react:
@ -11,6 +11,6 @@ services:
- ./src:/usr/src/app/src
- ./public:/usr/src/app/public
ports:
- "3000:3000"
- "9229:9229"
command: ["npm", "start"]
- '3000:3000'
- '9229:9229'
command: ['npm', 'start']

7088
03/package-lock.json generated

File diff suppressed because it is too large Load Diff

46
03/package.json

@ -1,31 +1,31 @@
{
"name": "03",
"version": "0.1.0",
"private": true,
"dependencies": {
"react": "^16.12.0",
"react-dom": "^16.12.0",
"react-scripts": "3.2.0"
'name': '03',
'version': '0.1.0',
'private': true,
'dependencies': {
'react': '^16.12.0',
'react-dom': '^16.12.0',
'react-scripts': '3.2.0'
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
'scripts': {
'start': 'react-scripts start',
'build': 'react-scripts build',
'test': 'react-scripts test',
'eject': 'react-scripts eject'
},
"eslintConfig": {
"extends": "react-app"
'eslintConfig': {
'extends': 'react-app'
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
'browserslist': {
'production': [
'>0.2%',
'not dead',
'not op_mini all'
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
'development': [
'last 1 chrome version',
'last 1 firefox version',
'last 1 safari version'
]
}
}

22
03/public/index.html

@ -1,26 +1,26 @@
<!DOCTYPE html>
<html lang="en">
<html lang='en'>
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta charset='utf-8' />
<link rel='icon' href='%PUBLIC_URL%/favicon.ico' />
<meta name='viewport' content='width=device-width, initial-scale=1' />
<meta name='theme-color' content='#000000' />
<meta
name="description"
content="Web site created using create-react-app"
name='description'
content='Web site created using create-react-app'
/>
<link rel="apple-touch-icon" href="logo192.png" />
<link rel='apple-touch-icon' href='logo192.png' />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<link rel='manifest' href='%PUBLIC_URL%/manifest.json' />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
Unlike '/favicon.ico' or 'favicon.ico', '%PUBLIC_URL%/favicon.ico' will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
@ -28,7 +28,7 @@
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<div id='root'></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.

4
03/src/App.js

@ -6,7 +6,7 @@ import './App.css'
class App extends React.Component {
constructor(props) {
super(props)
this.state = {username: "Placeholder"}
this.state = {username: 'Placeholder'}
}
handleUsernameChange(event) {
@ -19,7 +19,7 @@ class App extends React.Component {
render() {
return (
<div className="App">
<div className='App'>
<h1>Oy mate</h1>
<UserInput change={this.handleUsernameChange.bind(this)} username={this.state.username} />
<UserOutput username={this.state.username} />

6
03/src/index.css

@ -1,13 +1,13 @@
body {
margin: 0;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
"Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
code {
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
monospace;
}

Loading…
Cancel
Save