Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Current Feature Set #43

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
96e5c82
Current Feature Set
imcodingideas Apr 16, 2020
ab8fde7
Introduce Types and Webpack Plugin.
imcodingideas Apr 20, 2020
1d8017a
Introduced Terser Plugin and Optimized Production
imcodingideas Apr 20, 2020
ba00bea
Migrated App Component to TypeScript
imcodingideas Apr 20, 2020
4fa1120
Migrated useAgenda Hook to TypeScript
imcodingideas Apr 20, 2020
87bfb29
Migrated Banner Component to TypeScript
imcodingideas Apr 20, 2020
b706d0c
Migrated @hooks to typescript
imcodingideas Apr 20, 2020
5b3a527
Disabled eslint
imcodingideas Apr 20, 2020
434bcd9
Depercated Formik
imcodingideas Apr 20, 2020
b9ec02f
Introduced TypeScript to UI and Data Context
imcodingideas Apr 20, 2020
ba4e765
Introduced TypeScript to @components
imcodingideas Apr 20, 2020
bcbdb88
Introduced TypeScript to Region
imcodingideas Apr 20, 2020
92cde54
Introduced TypeScript to RightPanel
imcodingideas Apr 20, 2020
e8ee7da
Pass background color to RimView
imcodingideas Apr 20, 2020
62d5b88
Introduce TypeScript to RimView
imcodingideas Apr 20, 2020
1dd0ae0
Deprecate useDataContext
imcodingideas Apr 20, 2020
814ef0a
Introduce TypeScript to initialAppState
imcodingideas Apr 20, 2020
a6ea288
Keep consistency.
imcodingideas Apr 20, 2020
7dc7ad4
Migrate the Top Panel to TypeScript
imcodingideas Apr 20, 2020
594d099
Migrate Common Components to TypeScript
imcodingideas Apr 20, 2020
bc0965d
Rollback tags
imcodingideas Apr 20, 2020
6631e07
fixup
imcodingideas Apr 20, 2020
ce39716
Delete Conflicting file
imcodingideas Apr 20, 2020
18cc3de
removed right panel extra sizes
imcodingideas Apr 20, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
{
"presets": [
"@babel/preset-env",
"@babel/preset-react"
"@babel/preset-react",
"@babel/typescript"
],
"plugins": [
"@babel/plugin-proposal-optional-chaining"
]
}
}
143 changes: 2 additions & 141 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,142 +1,3 @@

module.exports = {
"extends": [
"airbnb",
"prettier",
"prettier/react",
"plugin:jsx-a11y/recommended"
],
"parser": "babel-eslint",
"parserOptions": {
"ecmaVersion": 2018,
"ecmaFeatures": {
"impliedStrict": true,
"classes": true
}
},
"env": {
"browser": true,
"node": true,
"jquery": true,
"jest": true
},
"rules": {
"no-debugger": 0,
"no-alert": 0,
"no-await-in-loop": 0,
"no-return-assign": [
"error",
"except-parens"
],
"no-restricted-syntax": [
2,
"ForInStatement",
"LabeledStatement",
"WithStatement"
],
"no-unused-vars": [
1,
{
"ignoreSiblings": true,
"argsIgnorePattern": "res|next|^err"
}
],
"prefer-const": [
"error",
{
"destructuring": "all",
}
],
"arrow-body-style": [
2,
"as-needed"
],
"no-unused-expressions": [
2,
{
"allowTaggedTemplates": true
}
],
"no-param-reassign": [
2,
{
"props": false
}
],
"no-console": 0,
"import/prefer-default-export": 0,
"import": 0,
"func-names": 0,
"space-before-function-paren": 0,
"comma-dangle": 0,
"max-len": 0,
"import/extensions": 0,
"no-underscore-dangle": 0,
"consistent-return": 0,
"react/display-name": 1,
"react/no-array-index-key": 0,
"react/react-in-jsx-scope": 0,
"react/prefer-stateless-function": 0,
"react/forbid-prop-types": 0,
"react/no-unescaped-entities": 0,
"jsx-a11y/accessible-emoji": 0,
"react/require-default-props": 0,
"react/jsx-filename-extension": [
1,
{
"extensions": [
".js",
".jsx"
]
}
],
"radix": 0,
"no-shadow": [
2,
{
"hoist": "all",
"allow": [
"resolve",
"reject",
"done",
"next",
"err",
"error"
]
}
],
"quotes": [
2,
"single",
{
"avoidEscape": true,
"allowTemplateLiterals": true
}
],
"prettier/prettier": [
"error",
{
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 80,
}
],
"jsx-a11y/href-no-hash": "off",
"jsx-a11y/anchor-is-valid": [
"warn",
{
"aspects": [
"invalidHref"
]
}
],
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn"
},
"plugins": [
"html",
"prettier",
"react-hooks",
"jsx-a11y"
]
}
extends: ['./js.config.js', './ts.config.js'],
};
8 changes: 4 additions & 4 deletions build-utils/webpack.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ const { CleanWebpackPlugin } = require('clean-webpack-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');

module.exports = {
entry: './src/index.js',
entry: './src/index.tsx',
module: {
rules: [
{
test: /\.(js|jsx)$/,
exclude: /node_modules/,
test: /\.(j|t)sx?$/,
use: ['babel-loader', 'eslint-loader'],
exclude: /node_modules/,
},
{
test: /\.svg$/,
Expand All @@ -34,7 +34,7 @@ module.exports = {
],
},
resolve: {
extensions: ['*', '.js', '.jsx'],
extensions: ['*', '.js', '.ts', '.jsx', '.tsx'],
},
plugins: [
new CleanWebpackPlugin(),
Expand Down
17 changes: 17 additions & 0 deletions build-utils/webpack.prod.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,26 @@
/* eslint-disable import/no-extraneous-dependencies */
const Dotenv = require('dotenv-webpack');
const TerserPlugin = require('terser-webpack-plugin');

module.exports = {
mode: 'production',
devtool: 'source-map',
optimization: {
occurrenceOrder: true,
removeEmptyChunks: true,
mangleWasmImports: true,
removeAvailableModules: true,
usedExports: true,
mergeDuplicateChunks: true,
minimize: true,
minimizer: [
new TerserPlugin({
parallel: true,
sourceMap: true,
extractComments: false,
}),
],
},
plugins: [
new Dotenv({
path: './.env.production',
Expand Down
5 changes: 1 addition & 4 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,7 @@ module.exports = {
// ],

// A map from regular expressions to module names that allow to stub out resources with a single module
moduleNameMapper: {
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/__mocks__/fileMock.js",
"\\.(css|less)$": "<rootDir>/__mocks__/styleMock.js"
},
// moduleNameMapper: {},

// An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader
// modulePathIgnorePatterns: [],
Expand Down
113 changes: 113 additions & 0 deletions js.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
module.exports = {
extends: [
'airbnb',
'prettier',
'prettier/react',
'plugin:jsx-a11y/recommended',
],
parser: 'babel-eslint',
parserOptions: {
ecmaVersion: 2018,
ecmaFeatures: {
impliedStrict: true,
classes: true,
},
},
env: {
browser: true,
node: true,
jquery: true,
jest: true,
},
rules: {
'no-debugger': 0,
'no-alert': 0,
'no-await-in-loop': 0,
'no-return-assign': ['error', 'except-parens'],
'no-restricted-syntax': [
2,
'ForInStatement',
'LabeledStatement',
'WithStatement',
],
'no-unused-vars': [
1,
{
ignoreSiblings: true,
argsIgnorePattern: 'res|next|^err',
},
],
'prefer-const': [
'error',
{
destructuring: 'all',
},
],
'arrow-body-style': [2, 'as-needed'],
'no-unused-expressions': [
2,
{
allowTaggedTemplates: true,
},
],
'no-param-reassign': [
2,
{
props: false,
},
],
'no-console': 0,
'import/prefer-default-export': 0,
import: 0,
'func-names': 0,
'space-before-function-paren': 0,
'comma-dangle': 0,
'max-len': 0,
'import/extensions': 0,
'no-underscore-dangle': 0,
'consistent-return': 0,
'react/display-name': 1,
'react/no-array-index-key': 0,
'react/react-in-jsx-scope': 0,
'react/prefer-stateless-function': 0,
'react/forbid-prop-types': 0,
'react/no-unescaped-entities': 0,
'jsx-a11y/accessible-emoji': 0,
'react/require-default-props': 0,
'react/jsx-filename-extension': [1, { extensions: ['.tsx', '.ts', '.js'] }],
radix: 0,
'no-shadow': [
2,
{
hoist: 'all',
allow: ['resolve', 'reject', 'done', 'next', 'err', 'error'],
},
],
quotes: [
2,
'single',
{
avoidEscape: true,
allowTemplateLiterals: true,
},
],
'prettier/prettier': [
'error',
{
trailingComma: 'es5',
singleQuote: true,
printWidth: 80,
},
],
'jsx-a11y/href-no-hash': 'off',
'jsx-a11y/anchor-is-valid': [
'warn',
{
aspects: ['invalidHref'],
},
],
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',
},
plugins: ['babel', 'html', 'prettier', 'react-hooks', 'jsx-a11y'],
};
Loading