Skip to content

Commit 66b9e86

Browse files
committedApr 18, 2018
Initial commit | adds basic setup
0 parents  commit 66b9e86

10 files changed

+6002
-0
lines changed
 

‎.babelrc

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"presets": ["es2015", "stage-2", "react"]
3+
}

‎.eslintrc

+180
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,180 @@
1+
{
2+
root: true,
3+
parser: 'babel-eslint',
4+
plugins: [/*'import', */'jsx-a11y', 'react'],
5+
env: {
6+
browser: true,
7+
commonjs: true,
8+
es6: true,
9+
jest: true,
10+
node: true
11+
},
12+
parserOptions: {
13+
ecmaVersion: 6,
14+
sourceType: 'module',
15+
ecmaFeatures: {
16+
jsx: true,
17+
generators: true,
18+
experimentalObjectRestSpread: true
19+
}
20+
},
21+
settings: {
22+
'import/ignore': [
23+
'node_modules',
24+
'\\.(json|css|jpg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm)$',
25+
],
26+
'import/extensions': ['.js'],
27+
'import/resolver': {
28+
node: {
29+
extensions: ['.js', '.json']
30+
}
31+
}
32+
},
33+
rules: {
34+
// http://eslint.org/docs/rules/
35+
'array-callback-return': 'warn',
36+
'camelcase': 'warn',
37+
'curly': 'warn',
38+
'default-case': ['warn', { commentPattern: '^no default$' }],
39+
'dot-location': ['warn', 'property'],
40+
'eol-last': 'warn',
41+
'eqeqeq': ['warn', 'always'],
42+
'indent': ['warn', 2, { "SwitchCase": 1 }],
43+
'guard-for-in': 'warn',
44+
'keyword-spacing': 'warn',
45+
'new-parens': 'warn',
46+
'no-array-constructor': 'warn',
47+
'no-caller': 'warn',
48+
'no-cond-assign': ['warn', 'always'],
49+
'no-const-assign': 'warn',
50+
'no-control-regex': 'warn',
51+
'no-delete-var': 'warn',
52+
'no-dupe-args': 'warn',
53+
'no-dupe-class-members': 'warn',
54+
'no-dupe-keys': 'warn',
55+
'no-duplicate-case': 'warn',
56+
'no-empty-character-class': 'warn',
57+
'no-empty-pattern': 'warn',
58+
'no-eval': 'warn',
59+
'no-ex-assign': 'warn',
60+
'no-extend-native': 'warn',
61+
'no-extra-bind': 'warn',
62+
'no-extra-label': 'warn',
63+
'no-fallthrough': 'warn',
64+
'no-func-assign': 'warn',
65+
'no-global-assign': 'warn',
66+
'no-implied-eval': 'warn',
67+
'no-invalid-regexp': 'warn',
68+
'no-iterator': 'warn',
69+
'no-label-var': 'warn',
70+
'no-labels': ['warn', { allowLoop: false, allowSwitch: false }],
71+
'no-lone-blocks': 'warn',
72+
'no-loop-func': 'warn',
73+
'no-mixed-operators': ['warn', {
74+
groups: [
75+
['&', '|', '^', '~', '<<', '>>', '>>>'],
76+
['==', '!=', '===', '!==', '>', '>=', '<', '<='],
77+
['&&', '||'],
78+
['in', 'instanceof']
79+
],
80+
allowSamePrecedence: false
81+
}],
82+
'no-multi-str': 'warn',
83+
'no-new-func': 'warn',
84+
'no-new-object': 'warn',
85+
'no-new-symbol': 'warn',
86+
'no-new-wrappers': 'warn',
87+
'no-obj-calls': 'warn',
88+
'no-octal': 'warn',
89+
'no-octal-escape': 'warn',
90+
'no-redeclare': 'warn',
91+
'no-regex-spaces': 'warn',
92+
'no-restricted-syntax': [
93+
'warn',
94+
'LabeledStatement',
95+
'WithStatement',
96+
],
97+
'no-script-url': 'warn',
98+
'no-self-assign': 'warn',
99+
'no-self-compare': 'warn',
100+
'no-sequences': 'warn',
101+
'no-shadow-restricted-names': 'warn',
102+
'no-sparse-arrays': 'warn',
103+
'no-template-curly-in-string': 'warn',
104+
'no-this-before-super': 'warn',
105+
'no-throw-literal': 'warn',
106+
'no-undef': 'warn',
107+
'no-unexpected-multiline': 'warn',
108+
'no-unreachable': 'warn',
109+
'no-unsafe-negation': 'warn',
110+
'no-unused-expressions': 'warn',
111+
'no-unused-labels': 'warn',
112+
'no-unused-vars': ['warn', { vars: 'local', args: 'none' }],
113+
'no-use-before-define': ['warn', 'nofunc'],
114+
'no-useless-computed-key': 'warn',
115+
'no-useless-concat': 'warn',
116+
'no-useless-constructor': 'warn',
117+
'no-useless-escape': 'warn',
118+
'no-useless-rename': ['warn', {
119+
ignoreDestructuring: false,
120+
ignoreImport: false,
121+
ignoreExport: false,
122+
}],
123+
'no-with': 'warn',
124+
'no-whitespace-before-property': 'warn',
125+
'object-curly-spacing': ['warn', 'always'],
126+
'operator-assignment': ['warn', 'always'],
127+
radix: 'warn',
128+
'require-yield': 'warn',
129+
'rest-spread-spacing': ['warn', 'never'],
130+
'semi': 'warn',
131+
strict: ['warn', 'never'],
132+
'unicode-bom': ['warn', 'never'],
133+
'use-isnan': 'warn',
134+
'valid-typeof': 'warn',
135+
'react/jsx-boolean-value': 'warn',
136+
'react/jsx-closing-bracket-location': 'warn',
137+
'react/jsx-curly-spacing': 'warn',
138+
'react/jsx-equals-spacing': ['warn', 'never'],
139+
'react/jsx-first-prop-new-line': ['warn', 'multiline'],
140+
'react/jsx-handler-names': 'warn',
141+
'react/jsx-indent': ['warn', 2],
142+
'react/jsx-indent-props': ['warn', 2],
143+
'react/jsx-key': 'warn',
144+
'react/jsx-max-props-per-line': 'warn',
145+
'react/jsx-no-bind': ['warn', {'allowArrowFunctions': true}],
146+
'react/jsx-no-comment-textnodes': 'warn',
147+
'react/jsx-no-duplicate-props': ['warn', { ignoreCase: true }],
148+
'react/jsx-no-undef': 'warn',
149+
'react/jsx-pascal-case': ['warn', {
150+
allowAllCaps: true,
151+
ignore: [],
152+
}],
153+
'react/jsx-sort-props': 'warn',
154+
'react/jsx-tag-spacing': 'warn',
155+
'react/jsx-uses-react': 'warn',
156+
'react/jsx-uses-vars': 'warn',
157+
'react/jsx-wrap-multilines': 'warn',
158+
'react/no-deprecated': 'warn',
159+
'react/no-did-mount-set-state': 'warn',
160+
'react/no-did-update-set-state': 'warn',
161+
'react/no-direct-mutation-state': 'warn',
162+
'react/no-is-mounted': 'warn',
163+
'react/no-unused-prop-types': 'warn',
164+
'react/prefer-es6-class': 'warn',
165+
'react/prefer-stateless-function': 'warn',
166+
'react/prop-types': 'warn',
167+
'react/react-in-jsx-scope': 'warn',
168+
'react/require-render-return': 'warn',
169+
'react/self-closing-comp': 'warn',
170+
'react/sort-comp': 'warn',
171+
'react/sort-prop-types': 'warn',
172+
'react/style-prop-object': 'warn',
173+
'react/void-dom-elements-no-children': 'warn',
174+
// https://github.com/evcohen/eslint-plugin-jsx-a11y/tree/master/docs/rules
175+
'jsx-a11y/aria-role': 'warn',
176+
'jsx-a11y/img-has-alt': 'warn',
177+
'jsx-a11y/img-redundant-alt': 'warn',
178+
'jsx-a11y/no-access-key': 'warn'
179+
}
180+
}

‎.gitignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.DS_Store
2+
build
3+
node_modules
4+
*.log

‎.npmignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.babelrc
2+
lib
3+
CODE_OF_CONDUCT.md

‎CODE_OF_CONDUCT.md

Whitespace-only changes.

‎README.md

Whitespace-only changes.

‎lib/elements/Button.js

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import styled from 'styled-components';
2+
const Button = styled.button`
3+
background: #1FB6FF;
4+
border: none;
5+
border-radius: 2px;
6+
color: #FFFFFF;
7+
cursor: pointer;
8+
display: inline-block;
9+
font-size: 16px;
10+
line-height: 40px;
11+
font-weight: 200;
12+
margin: 8px 0;
13+
outline: none;
14+
padding: 0 12px;
15+
text-transform: uppercase;
16+
transition: all 300ms ease;
17+
&:hover {
18+
background: #009EEB;
19+
}
20+
`;
21+
export default Button;

‎lib/index.js

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
import Button from './elements/Button’;
2+
module.exports = {
3+
Button,
4+
};

0 commit comments

Comments
 (0)