Skip to content

Commit 407276b

Browse files
committed
fix: don't lint otel-web package
1 parent 1309f4d commit 407276b

2 files changed

Lines changed: 16 additions & 9 deletions

File tree

lint-staged.config.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
module.exports = {
2+
'**/*.{ts,tsx}': (files) => {
3+
const cmds = [`prettier --write --ignore-unknown ${files.join(' ')}`];
4+
5+
// `otel-web` package does not have an eslint config yet
6+
const lintable = files.filter((f) => !f.includes('/packages/otel-web/'));
7+
8+
if (lintable.length) {
9+
cmds.push(`eslint --fix ${lintable.join(' ')}`);
10+
}
11+
12+
return cmds;
13+
},
14+
15+
'**/*.{json,yml}': 'prettier --write --ignore-unknown',
16+
};

package.json

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,6 @@
1818
"release:next": "npx nx run-many --target=build && yarn changeset version --snapshot next && npx nx run-many --target=postversion && yarn changeset publish --tag next",
1919
"prepare": "husky install"
2020
},
21-
"lint-staged": {
22-
"**/*.{ts,tsx}": [
23-
"prettier --write --ignore-unknown",
24-
"eslint --fix"
25-
],
26-
"**/*.{json,yml}": [
27-
"prettier --write --ignore-unknown"
28-
]
29-
},
3021
"devDependencies": {
3122
"@changesets/cli": "^2.26.1",
3223
"@types/debug": "^4.1.8",

0 commit comments

Comments
 (0)