Skip to content

Commit

Permalink
feat: use official eslint-plugin-prettier again, fix postcss config
Browse files Browse the repository at this point in the history
  • Loading branch information
JounQin committed Apr 15, 2021
1 parent 79df091 commit a05fefc
Show file tree
Hide file tree
Showing 11 changed files with 635 additions and 347 deletions.
6 changes: 6 additions & 0 deletions .stylelint.common.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": [
"@1stg/stylelint-config"
],
"ignoreFiles": "*.scss"
}
5 changes: 1 addition & 4 deletions .stylelintrc
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,5 @@
"@1stg/stylelint-config/scss",
"@1stg/stylelint-config/modules"
],
"ignoreFiles": "*.less",
"rules": {
"plugin/no-unsupported-browser-features": null
}
"ignoreFiles": "*.less"
}
11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"check:stylelint": "stylelint-config-prettier-check",
"check:tslint": "tslint-config-prettier-check ./tslint.json",
"lint": "run-p lint:*",
"lint:css": "stylelint --cache --config stylelint.common.js 'tests/*.{css,html,less}'",
"lint:css": "stylelint --cache --config .stylelint.common.json 'tests/*.{css,html,less}'",
"lint:es": "cross-env PARSER_NO_WATCH=true eslint . --cache --ext js,jsx,md,mdx,ts,tsx,vue -f friendly",
"lint:scss": "stylelint --cache 'tests/*.{scss,vue}'",
"lint:ts": "tslint -p . -t stylish",
Expand All @@ -25,26 +25,27 @@
"typecov": "type-coverage"
},
"devDependencies": {
"@angular/core": "^11.2.9",
"@angular/core": "^11.2.10",
"@types/jest": "^26.0.22",
"@types/node": "^14.14.37",
"@types/node": "^14.14.39",
"@types/react": "^17.0.3",
"@types/unist": "^2.0.3",
"core-js": "^3.10.1",
"lerna": "^4.0.0",
"npm-run-all": "^4.1.5",
"postcss": "^8.2.10",
"react": "^17.0.2",
"rxjs": "^6.6.7",
"svelte": "^3.37.0",
"ts-jest": "^26.5.4",
"tslint": "^6.1.3",
"type-coverage": "^2.17.0",
"type-coverage": "^2.17.2",
"typescript": "^4.2.4",
"vue": "^2.6.12",
"yarn-deduplicate": "^3.1.0"
},
"resolutions": {
"@babel/core": "^7.13.14",
"@babel/core": "^7.13.15",
"prettier": "^2.2.1"
},
"typeCoverage": {
Expand Down
4 changes: 2 additions & 2 deletions packages/app-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
"@1stg/stylelint-config": "^1.3.0",
"@pkgr/es-modules": "^0.4.0",
"@pkgr/imagemin": "^0.5.0",
"browserslist": "^4.16.3",
"postcss": "^8.2.9",
"browserslist": "^4.16.4",
"postcss": "^8.2.10",
"stylelint": "^13.12.0"
},
"publishConfig": {
Expand Down
4 changes: 2 additions & 2 deletions packages/babel-preset/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
"dependencies": {
"@babel/helper-plugin-utils": "^7.13.0",
"@babel/plugin-proposal-class-properties": "^7.13.0",
"@babel/plugin-proposal-decorators": "^7.13.5",
"@babel/preset-env": "^7.13.12",
"@babel/plugin-proposal-decorators": "^7.13.15",
"@babel/preset-env": "^7.13.15",
"@babel/preset-react": "^7.13.13",
"@babel/preset-typescript": "^7.13.0",
"@pkgr/utils": "^0.6.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/common-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
"@1stg/remark-config": "^1.1.0",
"@1stg/simple-git-hooks": "^0.1.2",
"@1stg/tsconfig": "^1.3.0",
"@babel/core": "^7.13.14",
"@babel/core": "^7.13.15",
"@commitlint/cli": "^12.1.1",
"eslint": "^7.23.0",
"eslint": "^7.24.0",
"lint-staged": "^10.5.4",
"prettier": "^2.2.1",
"simple-git-hooks": "^2.3.1",
Expand Down
20 changes: 10 additions & 10 deletions packages/eslint-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,32 +11,32 @@
},
"dependencies": {
"@babel/eslint-parser": "^7.13.14",
"@babel/eslint-plugin": "^7.13.10",
"@babel/eslint-plugin": "^7.13.15",
"@pkgr/utils": "^0.6.0",
"@typescript-eslint/eslint-plugin": "^4.21.0",
"@typescript-eslint/eslint-plugin-tslint": "^4.21.0",
"@typescript-eslint/parser": "^4.21.0",
"eslint-config-prettier": "^8.1.0",
"@typescript-eslint/eslint-plugin": "^4.22.0",
"@typescript-eslint/eslint-plugin-tslint": "^4.22.0",
"@typescript-eslint/parser": "^4.22.0",
"eslint-config-prettier": "^8.2.0",
"eslint-config-standard": "^16.0.2",
"eslint-config-standard-jsx": "^10.0.0",
"eslint-config-standard-react": "^11.0.1",
"eslint-formatter-friendly": "^7.0.0",
"eslint-import-resolver-typescript": "^2.4.0",
"eslint-plugin-eslint-comments": "^3.2.0",
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-jest": "^24.3.4",
"eslint-plugin-jest": "^24.3.5",
"eslint-plugin-jsdoc": "^32.3.0",
"eslint-plugin-mdx": "^1.12.0",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-prettier": "npm:@rxts/eslint-plugin-prettier@^3.4.0-1",
"eslint-plugin-promise": "^4.3.1",
"eslint-plugin-react": "^7.23.1",
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-promise": "^5.1.0",
"eslint-plugin-react": "^7.23.2",
"eslint-plugin-react-hooks": "^4.2.0",
"eslint-plugin-sonar": "^0.4.0",
"eslint-plugin-sonarjs": "^0.6.0",
"eslint-plugin-svelte": "^1.1.2",
"eslint-plugin-unicorn": "^29.0.0",
"eslint-plugin-vue": "^7.8.0"
"eslint-plugin-vue": "^7.9.0"
},
"publishConfig": {
"access": "public"
Expand Down
12 changes: 6 additions & 6 deletions packages/postcss-config/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ module.exports = ({
...options
} = {}) => {
const plugins = [
require('postcss-preset-env', presetEnv),
require('postcss-import', importOptions),
require('postcss-normalize', normalize),
require('postcss-url', url),
require('postcss-preset-env')(presetEnv),
require('postcss-import')(importOptions),
require('postcss-normalize')(normalize),
require('postcss-url')(url),
require('autoprefixer'),
]

Expand All @@ -23,7 +23,7 @@ module.exports = ({

if (modules) {
plugins.push(
require('postcss-modules', {
require('postcss-modules')({
globalModulePaths: [
/[/\\]node_modules[/\\]/,
/(\bglobals?[/\\][\w-]+|\.globals?)\.(p?css|less|s[ac]ss|styl(us)?)$/,
Expand All @@ -38,7 +38,7 @@ module.exports = ({

if (isProd) {
plugins.push(
require('cssnano', {
require('cssnano')({
preset: [
advanced ? 'advanced' : 'default',
{
Expand Down
4 changes: 2 additions & 2 deletions packages/postcss-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
},
"dependencies": {
"autoprefixer": "^10.2.5",
"cssnano": "^4.1.11",
"cssnano-preset-advanced": "^4.0.8",
"cssnano": "^5.0.1",
"cssnano-preset-advanced": "^5.0.0",
"postcss-import": "^14.0.1",
"postcss-modules": "^4.0.0",
"postcss-normalize": "^9.0.0",
Expand Down
9 changes: 0 additions & 9 deletions stylelint.common.js

This file was deleted.

0 comments on commit a05fefc

Please sign in to comment.