Skip to content

Commit 54b0671

Browse files
committed
Init commit
1 parent 75d104a commit 54b0671

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+24831
-0
lines changed

.babelrc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"presets": [
3+
["@babel/preset-env", {"useBuiltIns": "usage"}],
4+
"@babel/preset-react"
5+
]
6+
}

.editorconfig

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
################################################
2+
# ╔═╗╔╦╗╦╔╦╗╔═╗╦═╗┌─┐┌─┐┌┐┌┌─┐┬┌─┐
3+
# ║╣ ║║║ ║ ║ ║╠╦╝│ │ ││││├┤ ││ ┬
4+
# o╚═╝═╩╝╩ ╩ ╚═╝╩╚═└─┘└─┘┘└┘└ ┴└─┘
5+
#
6+
# > Formatting conventions for your Sails app.
7+
#
8+
# This file (`.editorconfig`) exists to help
9+
# maintain consistent formatting throughout the
10+
# files in your Sails app.
11+
#
12+
# For the sake of convention, the Sails team's
13+
# preferred settings are included here out of the
14+
# box. You can also change this file to fit your
15+
# team's preferences (for example, if all of the
16+
# developers on your team have a strong preference
17+
# for tabs over spaces),
18+
#
19+
# To review what each of these options mean, see:
20+
# http://editorconfig.org/
21+
#
22+
################################################
23+
root = true
24+
25+
[*]
26+
indent_style = space
27+
indent_size = 4
28+
end_of_line = lf
29+
charset = utf-8
30+
trim_trailing_whitespace = true
31+
insert_final_newline = true

.eslintignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
assets/dependencies/**/*.js
2+
views/**/*.ejs
3+

.eslintrc

Lines changed: 227 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,227 @@
1+
{
2+
// ╔═╗╔═╗╦ ╦╔╗╔╔╦╗┬─┐┌─┐
3+
// ║╣ ╚═╗║ ║║║║ ║ ├┬┘│
4+
// o╚═╝╚═╝╩═╝╩╝╚╝ ╩ ┴└─└─┘
5+
// A set of basic code conventions designed to encourage quality and consistency
6+
// across your Sails app's code base. These rules are checked against
7+
// automatically any time you run `npm test`.
8+
//
9+
// > An additional eslintrc override file is included in the `assets/` folder
10+
// > right out of the box. This is specifically to allow for variations in acceptable
11+
// > global variables between front-end JavaScript code designed to run in the browser
12+
// > vs. backend code designed to run in a Node.js/Sails process.
13+
//
14+
// > Note: If you're using mocha, you'll want to add an extra override file to your
15+
// > `test/` folder so that eslint will tolerate mocha-specific globals like `before`
16+
// > and `describe`.
17+
// Designed for ESLint v4.
18+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
19+
// For more information about any of the rules below, check out the relevant
20+
// reference page on eslint.org. For example, to get details on "no-sequences",
21+
// you would visit `http://eslint.org/docs/rules/no-sequences`. If you're unsure
22+
// or could use some advice, come by https://sailsjs.com/support.
23+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
24+
25+
"env": {
26+
"node": true,
27+
"es6": true
28+
},
29+
"extends": ["eslint:recommended", "plugin:react/all"],
30+
"plugins": [
31+
"react"
32+
],
33+
"parser": "babel-eslint",
34+
"parserOptions": {
35+
"ecmaFeatures": {
36+
"jsx": true,
37+
"modules": true
38+
},
39+
"ecmaVersion": 6
40+
},
41+
"globals": {
42+
// If "no-undef" is enabled below, be sure to list all global variables that
43+
// are used in this app's backend code (including the globalIds of models):
44+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
45+
"Promise": true,
46+
"sails": true,
47+
"_": true,
48+
"process": true
49+
// …and any others (e.g. `"Organization": true`)
50+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
51+
},
52+
"rules": {
53+
"block-scoped-var": [
54+
"error"
55+
],
56+
"callback-return": [
57+
"error",
58+
[
59+
"done",
60+
"proceed",
61+
"next",
62+
"onwards",
63+
"callback",
64+
"cb"
65+
]
66+
],
67+
"camelcase": [
68+
"warn",
69+
{
70+
"properties": "always"
71+
}
72+
],
73+
"comma-style": [
74+
"warn",
75+
"last"
76+
],
77+
"curly": [
78+
"warn"
79+
],
80+
"eqeqeq": [
81+
"error",
82+
"always"
83+
],
84+
"eol-last": [
85+
"warn"
86+
],
87+
"handle-callback-err": [
88+
"error"
89+
],
90+
"indent": [
91+
"warn",
92+
4,
93+
{
94+
"SwitchCase": 1,
95+
"MemberExpression": "off",
96+
"FunctionDeclaration": {
97+
"body": 1,
98+
"parameters": "off"
99+
},
100+
"FunctionExpression": {
101+
"body": 1,
102+
"parameters": "off"
103+
},
104+
"CallExpression": {
105+
"arguments": "off"
106+
},
107+
"ArrayExpression": 1,
108+
"ObjectExpression": 1,
109+
"ignoredNodes": [
110+
"ConditionalExpression"
111+
]
112+
}
113+
],
114+
"linebreak-style": [
115+
"error",
116+
"unix"
117+
],
118+
"no-dupe-keys": [
119+
"error"
120+
],
121+
"no-duplicate-case": [
122+
"error"
123+
],
124+
"no-extra-semi": [
125+
"warn"
126+
],
127+
"no-labels": [
128+
"error"
129+
],
130+
"no-mixed-spaces-and-tabs": [
131+
2,
132+
"smart-tabs"
133+
],
134+
"no-redeclare": [
135+
"warn"
136+
],
137+
"no-return-assign": [
138+
"error",
139+
"always"
140+
],
141+
"no-sequences": [
142+
"error"
143+
],
144+
"no-trailing-spaces": [
145+
"off"
146+
],
147+
"no-undef": [
148+
"off"
149+
],
150+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
151+
// ^^Note: If this "no-undef" rule is enabled (set to `["error"]`), then all model globals
152+
// (e.g. `"Organization": true`) should be included above under "globals".
153+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
154+
"no-unexpected-multiline": [
155+
"warn"
156+
],
157+
"no-unreachable": [
158+
"warn"
159+
],
160+
"no-unused-vars": [
161+
"warn",
162+
{
163+
"caughtErrors": "all",
164+
"caughtErrorsIgnorePattern": "^unused($|[A-Z].*$)",
165+
"argsIgnorePattern": "^unused($|[A-Z].*$)",
166+
"varsIgnorePattern": "^unused($|[A-Z].*$)"
167+
}
168+
],
169+
"no-use-before-define": [
170+
"error",
171+
{
172+
"functions": false
173+
}
174+
],
175+
"one-var": [
176+
"off",
177+
"never"
178+
],
179+
"prefer-arrow-callback": [
180+
"warn",
181+
{
182+
"allowNamedFunctions": true
183+
}
184+
],
185+
"quotes": [
186+
"warn",
187+
"single",
188+
{
189+
"avoidEscape": false,
190+
"allowTemplateLiterals": true
191+
}
192+
],
193+
"react/static-property-placement": "off",
194+
"react/jsx-one-expression-per-line": "off",
195+
"react/destructuring-assignment": "off",
196+
"react/jsx-no-literals": "off",
197+
"react/jsx-max-props-per-line": "off",
198+
"react/jsx-sort-props": "off",
199+
"react/jsx-max-depth": "off",
200+
"react/no-unescaped-entities": "off",
201+
"react/jsx-indent-props": "off",
202+
"react/no-set-state": "off",
203+
"react/require-optimization": "off",
204+
"no-irregular-whitespace": "off",
205+
"react/forbid-component-props": "off",
206+
"react/jsx-no-bind": "off",
207+
"react/forbid-prop-types": "off",
208+
"react/no-multi-comp": "off",
209+
"react/jsx-handler-names": "off",
210+
"no-inner-declarations": "off",
211+
"semi": [
212+
"warn",
213+
"always"
214+
],
215+
"semi-spacing": [
216+
"warn",
217+
{
218+
"before": false,
219+
"after": true
220+
}
221+
],
222+
"semi-style": [
223+
"warn",
224+
"last"
225+
]
226+
}
227+
}

0 commit comments

Comments
 (0)