mirror of
https://github.com/Telecominfraproject/wlan-cloud-ui.git
synced 2025-10-29 09:52:36 +00:00
init
This commit is contained in:
3
.babelrc
Normal file
3
.babelrc
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"presets": ["@babel/preset-env", "@babel/preset-react"]
|
||||
}
|
||||
19
.editorconfig
Normal file
19
.editorconfig
Normal file
@@ -0,0 +1,19 @@
|
||||
# http://editorconfig.org
|
||||
root = true
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
indent_size = 2
|
||||
indent_style = space
|
||||
insert_final_newline = true
|
||||
max_line_length = 100
|
||||
trim_trailing_whitespace = true
|
||||
[*.md]
|
||||
max_line_length = 0
|
||||
trim_trailing_whitespace = false
|
||||
[{Makefile,**.mk}]
|
||||
# Use tabs for indentation (Makefiles require tabs)
|
||||
indent_style = tab
|
||||
[*.scss]
|
||||
indent_size = 2
|
||||
indent_style = space
|
||||
31
.eslintrc
Normal file
31
.eslintrc
Normal file
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"extends": ["airbnb", "prettier", "prettier/react"],
|
||||
"plugins": ["prettier"],
|
||||
"rules": {
|
||||
"react/jsx-filename-extension": [
|
||||
1,
|
||||
{
|
||||
"extensions": [".js", ".jsx"]
|
||||
}
|
||||
],
|
||||
"react/prop-types": 0,
|
||||
"no-underscore-dangle": 0,
|
||||
"import/imports-first": ["error", "absolute-first"],
|
||||
"import/newline-after-import": "error",
|
||||
"import/prefer-default-export": 0,
|
||||
"semi": "error"
|
||||
},
|
||||
"globals": {
|
||||
"window": true,
|
||||
"document": true,
|
||||
"localStorage": true,
|
||||
"FormData": true,
|
||||
"FileReader": true,
|
||||
"Blob": true,
|
||||
"navigator": true,
|
||||
"Headers": true,
|
||||
"Request": true,
|
||||
"fetch": true
|
||||
},
|
||||
"parser": "babel-eslint"
|
||||
}
|
||||
23
.gitignore
vendored
Normal file
23
.gitignore
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
|
||||
|
||||
# dependencies
|
||||
/node_modules
|
||||
/.pnp
|
||||
.pnp.js
|
||||
|
||||
# testing
|
||||
/coverage
|
||||
|
||||
# production
|
||||
/build
|
||||
|
||||
# misc
|
||||
.DS_Store
|
||||
.env.local
|
||||
.env.development.local
|
||||
.env.test.local
|
||||
.env.production.local
|
||||
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
4
.prettierrc
Normal file
4
.prettierrc
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"singleQuote": true,
|
||||
"trailingComma": "es5"
|
||||
}
|
||||
6
app/index.js
Normal file
6
app/index.js
Normal file
@@ -0,0 +1,6 @@
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
|
||||
const App = () => <h1>ConnectUs</h1>;
|
||||
|
||||
ReactDOM.render(<App />, document.getElementById('root'));
|
||||
11
index.html
Normal file
11
index.html
Normal file
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>ConnectUs</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
<script src="./dist/bundle.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
9615
package-lock.json
generated
Normal file
9615
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
56
package.json
Normal file
56
package.json
Normal file
@@ -0,0 +1,56 @@
|
||||
{
|
||||
"name": "cu-portal",
|
||||
"version": "0.1.0",
|
||||
"author": "ConnectUs",
|
||||
"description": "",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1",
|
||||
"start": "webpack-dev-server --mode development",
|
||||
"format": "prettier --write \"src/**/*.js\"",
|
||||
"eslint-fix": "eslint --fix \"src/**/*.js\"",
|
||||
"build": "webpack --mode production"
|
||||
},
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"react": "^16.13.0",
|
||||
"react-dom": "^16.13.0",
|
||||
"terser-webpack-plugin": "^2.3.5"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.8.7",
|
||||
"@babel/preset-env": "^7.8.7",
|
||||
"@babel/preset-react": "^7.8.3",
|
||||
"babel-eslint": "^10.1.0",
|
||||
"babel-loader": "^8.0.6",
|
||||
"eslint": "^6.8.0",
|
||||
"eslint-config-airbnb": "^18.0.1",
|
||||
"eslint-config-prettier": "^6.10.0",
|
||||
"eslint-config-react": "^1.1.7",
|
||||
"eslint-loader": "^3.0.3",
|
||||
"eslint-plugin-import": "^2.20.1",
|
||||
"eslint-plugin-jsx-a11y": "^6.2.3",
|
||||
"eslint-plugin-prettier": "^3.1.2",
|
||||
"eslint-plugin-react": "^7.19.0",
|
||||
"eslint-plugin-react-hooks": "^2.5.0",
|
||||
"husky": "^4.2.3",
|
||||
"lint-staged": "^10.0.8",
|
||||
"prettier": "^1.19.1",
|
||||
"pretty-quick": "^2.0.1",
|
||||
"webpack": "^4.42.0",
|
||||
"webpack-cli": "^3.3.11",
|
||||
"webpack-dev-server": "^3.10.3"
|
||||
},
|
||||
"precommit": "NODE_ENV=production lint-staged",
|
||||
"lint-staged": {
|
||||
"*.{js,jsx}": [
|
||||
"pretty-quick --staged",
|
||||
"eslint src/ --fix",
|
||||
"git add"
|
||||
]
|
||||
},
|
||||
"husky": {
|
||||
"hooks": {
|
||||
"pre-commit": "lint-staged"
|
||||
}
|
||||
}
|
||||
}
|
||||
30
webpack.config.js
Normal file
30
webpack.config.js
Normal file
@@ -0,0 +1,30 @@
|
||||
const TerserPlugin = require('terser-webpack-plugin');
|
||||
|
||||
module.exports = {
|
||||
entry: './src/index.js',
|
||||
output: {
|
||||
path: `${__dirname }/dist`,
|
||||
publicPath: '/',
|
||||
filename: 'bundle.js',
|
||||
},
|
||||
devServer: {
|
||||
contentBase: './dist',
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: /\.(js|jsx)$/,
|
||||
exclude: /node_modules/,
|
||||
use: ['babel-loader', 'eslint-loader'],
|
||||
},
|
||||
],
|
||||
},
|
||||
mode: 'production',
|
||||
optimization: {
|
||||
minimizer: [
|
||||
new TerserPlugin({
|
||||
/* additional options here */
|
||||
}),
|
||||
],
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user