I referenced https://facelessuser.github.io/wcmatch/glob/ and it says that
+(pattern_list) : The pattern matches if one or more occurrences of any of the patterns in the pattern_list match the input string. Requires the EXTGLOB flag.
{} : Bash style brace expansions. This is applied to patterns before anything else. Requires the BRACE flag.
I can see that the description is different for each of them, but hard to understand with the actual example.
For example, what is the difference between those two below?
"lint-staged": {
"src/**/*.{js,jsx,ts,tsx,json,css}": [
"prettier --write",
"eslint --fix src/",
"tslint --fix --project .",
"git add"
]
},
"lint-staged": {
"src/**/*.+(js|jsx|ts|tsx|json|css)": [
"prettier --write",
"eslint --fix src/",
"tslint --fix --project .",
"git add"
]
},
Any advice would be appreciated!