Skip to content

Commit fe0a6b5

Browse files
committed
build: firts commit
0 parents  commit fe0a6b5

26 files changed

+12347
-0
lines changed

.eslintignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
node_modules
2+
public
3+
build
4+
dist

.eslintrc.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"env": {
3+
"browser": true,
4+
"es2021": true,
5+
"webextensions": true
6+
},
7+
"extends": ["eslint:recommended", "plugin:react/recommended", "prettier"],
8+
"parserOptions": {
9+
"ecmaFeatures": {
10+
"jsx": true
11+
},
12+
"ecmaVersion": 12,
13+
"sourceType": "module"
14+
},
15+
"settings": {
16+
"react": {
17+
"version": "detect"
18+
}
19+
},
20+
"plugins": ["react"],
21+
"rules": {
22+
"react/jsx-uses-react": "error",
23+
"react/jsx-uses-vars": "error",
24+
"react/react-in-jsx-scope": "off"
25+
}
26+
}

.gitignore

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2+
3+
# dependencies
4+
/node_modules
5+
/.pnp
6+
.pnp.js
7+
8+
# testing
9+
/coverage
10+
11+
# production
12+
/build
13+
/dist
14+
15+
# misc
16+
.DS_Store
17+
.env.local
18+
.env.development.local
19+
.env.test.local
20+
.env.production.local
21+
.eslintcache
22+
23+
#debug
24+
npm-debug.log*
25+
yarn-debug.log*
26+
yarn-error.log*

.prettierignore

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.cache
2+
.next
3+
public
4+
package-lock.json
5+
yarn.lock
6+
node_modules
7+
dist
8+
build
9+
coverage

.prettierrc.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"semi": false,
3+
"singleQuote": true,
4+
"jsxSingleQuote": true,
5+
"jsxBracketSameLine": true
6+
}

commitlint.config.js

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
module.exports = {
2+
extends: ['@commitlint/config-conventional'],
3+
rules: {
4+
'type-enum': [
5+
2,
6+
'always',
7+
[
8+
'build',
9+
'chore',
10+
'ci',
11+
'docs',
12+
'improvement',
13+
'feat',
14+
'fix',
15+
'perf',
16+
'refactor',
17+
'revert',
18+
'style',
19+
'test',
20+
],
21+
],
22+
},
23+
}

config-overrides.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
const multipleEntry = require("react-app-rewire-multiple-entry")([
2+
{
3+
entry: "src/popup/index.js",
4+
template: "public/popup.html",
5+
outPath: "/popup.html",
6+
},
7+
{
8+
entry: "src/options/index.js",
9+
template: "public/index.html",
10+
outPath: "/index.html",
11+
},
12+
]);
13+
14+
module.exports = {
15+
webpack: function (config) {
16+
multipleEntry.addMultiEntry(config);
17+
return config;
18+
},
19+
};

package.json

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
{
2+
"name": "react-env-extension",
3+
"version": "0.1.0",
4+
"private": false,
5+
"scripts": {
6+
"start": "react-app-rewired start",
7+
"build": "./scripts/build.sh",
8+
"test": "react-app-rewired test",
9+
"serve": "serve -s build",
10+
"lint": "./node_modules/.bin/prettier --write \"src/**/*.{jsx,js}\" && eslint --fix --ext .jsx,.js src/"
11+
},
12+
"browserslist": {
13+
"production": [
14+
">0.2%",
15+
"not dead",
16+
"not op_mini all"
17+
],
18+
"development": [
19+
"last 1 chrome version",
20+
"last 1 firefox version",
21+
"last 1 safari version"
22+
]
23+
},
24+
"dependencies": {
25+
"react": "^17.0.1",
26+
"react-dom": "^17.0.1",
27+
"react-scripts": "^4.0.0"
28+
},
29+
"devDependencies": {
30+
"@commitlint/cli": "^11.0.0",
31+
"@commitlint/config-conventional": "^11.0.0",
32+
"eslint": "^7.18.0",
33+
"eslint-config-prettier": "^7.2.0",
34+
"eslint-plugin-react": "^7.22.0",
35+
"husky": "^4.3.8",
36+
"prettier": "^2.2.1",
37+
"react-app-rewire-multiple-entry": "^2.2.1",
38+
"react-app-rewired": "^2.1.6",
39+
"serve": "^11.3.2"
40+
},
41+
"husky": {
42+
"hooks": {
43+
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS",
44+
"pre-commit": "yarn lint"
45+
}
46+
}
47+
}

public/favicon.ico

11 KB
Binary file not shown.

public/icons/logo128.png

5.22 KB
Loading

0 commit comments

Comments
 (0)