Cheeky lint

This commit is contained in:
Jorik Schellekens 2020-07-30 13:34:29 +01:00
parent 281f9ed766
commit eeb119ecb3
4 changed files with 116 additions and 116 deletions

View File

@ -1,15 +1,15 @@
module.exports = { module.exports = {
stories: ['../src/**/*.stories.tsx'], stories: ['../src/**/*.stories.tsx'],
addons: [ addons: [
'@storybook/preset-create-react-app', '@storybook/preset-create-react-app',
'@storybook/addon-actions', '@storybook/addon-actions',
'@storybook/addon-links', '@storybook/addon-links',
'@storybook/addon-storysource', '@storybook/addon-storysource',
'@storybook/addon-viewport/register', '@storybook/addon-viewport/register',
'@storybook/addon-a11y/register', '@storybook/addon-a11y/register',
'@storybook/addon-knobs/register', '@storybook/addon-knobs/register',
'@storybook/addon-actions/register', '@storybook/addon-actions/register',
'storybook-addon-designs', 'storybook-addon-designs',
'@storybook/addon-backgrounds/register', '@storybook/addon-backgrounds/register',
], ],
}; };

View File

@ -11,7 +11,7 @@ import { addParameters } from '@storybook/react';
import "../src/index.scss"; import "../src/index.scss";
addDecorator( addDecorator(
storyFn => <div style={{ textAlign: 'center' }}>{storyFn()}</div> storyFn => <div style={{ textAlign: 'center' }}>{storyFn()}</div>
); );
addDecorator(withA11y); addDecorator(withA11y);
@ -21,8 +21,8 @@ addDecorator(withKnobs);
addDecorator(withDesign); addDecorator(withDesign);
addParameters({ addParameters({
backgrounds: [ backgrounds: [
{name: 'light', value: '#F4F4F4'}, {name: 'light', value: '#F4F4F4'},
{name: 'white', value: '#FFFFFF', default: true}, {name: 'white', value: '#FFFFFF', default: true},
] ],
}); });

View File

@ -1,78 +1,78 @@
{ {
"name": "matrix.to", "name": "matrix.to",
"version": "0.1.0", "version": "0.1.0",
"private": true, "private": true,
"dependencies": { "dependencies": {
"classnames": "^2.2.6", "classnames": "^2.2.6",
"formik": "^2.1.4", "formik": "^2.1.4",
"react": "^16.13.1", "react": "^16.13.1",
"react-dom": "^16.13.1", "react-dom": "^16.13.1",
"react-scripts": "3.4.1", "react-scripts": "3.4.1",
"yup": "^0.29.1" "yup": "^0.29.1"
}, },
"scripts": { "scripts": {
"start": "react-scripts start", "start": "react-scripts start",
"build": "react-scripts build", "build": "react-scripts build",
"test": "react-scripts test", "test": "react-scripts test",
"eject": "react-scripts eject", "eject": "react-scripts eject",
"lint:fix": "eslint src/**/*.ts src/**/*.tsx --fix", "lint:fix": "eslint src/**/*.ts src/**/*.tsx --fix",
"storybook": "start-storybook -p 9009 -s public", "storybook": "start-storybook -p 9009 -s public",
"build-storybook": "build-storybook -s public" "build-storybook": "build-storybook -s public"
}, },
"lint-staged": { "lint-staged": {
"src/**/*.{js,jsx,ts,tsx}": [ "src/**/*.{js,jsx,ts,tsx}": [
"eslint --fix", "eslint --fix",
"prettier --write --tab-width 4", "prettier --write --tab-width 4",
"git add" "git add"
], ],
"src/**/*.{json,css,scss,md}": [ "src/**/*.{json,css,scss,md}": [
"prettier --write --tab-width 4", "prettier --write --tab-width 4",
"git add" "git add"
] ]
}, },
"husky": { "husky": {
"hooks": { "hooks": {
"pre-commit": "lint-staged" "pre-commit": "lint-staged"
}
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@storybook/addon-a11y": "^5.3.19",
"@storybook/addon-actions": "^5.3.19",
"@storybook/addon-backgrounds": "^5.3.19",
"@storybook/addon-knobs": "^5.3.19",
"@storybook/addon-links": "^5.3.19",
"@storybook/addon-storysource": "^5.3.19",
"@storybook/addon-viewport": "^5.3.19",
"@storybook/addons": "^5.3.19",
"@storybook/preset-create-react-app": "^3.1.4",
"@storybook/react": "^5.3.19",
"@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.3.2",
"@testing-library/user-event": "^7.1.2",
"@types/classnames": "^2.2.10",
"@types/jest": "^24.0.0",
"@types/node": "^12.0.0",
"@types/react": "^16.9.0",
"@types/react-dom": "^16.9.0",
"@types/yup": "^0.29.3",
"eslint-config-matrix-org": "^0.1.0",
"husky": "^4.2.5",
"lint-staged": "^10.2.7",
"node-sass": "^4.14.1",
"prettier": "^2.0.5",
"storybook-addon-designs": "^5.4.0",
"typescript": "~3.7.2"
} }
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@storybook/addon-a11y": "^5.3.19",
"@storybook/addon-actions": "^5.3.19",
"@storybook/addon-backgrounds": "^5.3.19",
"@storybook/addon-knobs": "^5.3.19",
"@storybook/addon-links": "^5.3.19",
"@storybook/addon-storysource": "^5.3.19",
"@storybook/addon-viewport": "^5.3.19",
"@storybook/addons": "^5.3.19",
"@storybook/preset-create-react-app": "^3.1.4",
"@storybook/react": "^5.3.19",
"@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.3.2",
"@testing-library/user-event": "^7.1.2",
"@types/classnames": "^2.2.10",
"@types/jest": "^24.0.0",
"@types/node": "^12.0.0",
"@types/react": "^16.9.0",
"@types/react-dom": "^16.9.0",
"@types/yup": "^0.29.3",
"eslint-config-matrix-org": "^0.1.0",
"husky": "^4.2.5",
"lint-staged": "^10.2.7",
"node-sass": "^4.14.1",
"prettier": "^2.0.5",
"storybook-addon-designs": "^5.4.0",
"typescript": "~3.7.2"
}
} }

View File

@ -1,25 +1,25 @@
{ {
"compilerOptions": { "compilerOptions": {
"target": "es5", "target": "es5",
"lib": [ "lib": [
"dom", "dom",
"dom.iterable", "dom.iterable",
"esnext" "esnext"
], ],
"allowJs": false, "allowJs": false,
"skipLibCheck": true, "skipLibCheck": true,
"esModuleInterop": true, "esModuleInterop": true,
"allowSyntheticDefaultImports": true, "allowSyntheticDefaultImports": true,
"strict": true, "strict": true,
"forceConsistentCasingInFileNames": true, "forceConsistentCasingInFileNames": true,
"module": "esnext", "module": "esnext",
"moduleResolution": "node", "moduleResolution": "node",
"resolveJsonModule": true, "resolveJsonModule": true,
"isolatedModules": true, "isolatedModules": true,
"noEmit": true, "noEmit": true,
"jsx": "react" "jsx": "react"
}, },
"include": [ "include": [
"src" "src"
] ]
} }